Commit 805d9f38 authored by Jerome Chauveau's avatar Jerome Chauveau
Browse files

Debug handler clavier. #34

parent ecb1c623
Loading
Loading
Loading
Loading
+38 −35
Original line number Diff line number Diff line
@@ -122,10 +122,12 @@ export default {
      if (e.defaultPrevented) {
        return;
      }
      // handler stopped if dialog box is displayed
      if(document.querySelector('.v-dialog.v-dialog--active'))
        return;
      if (e.key === 'ArrowRight') {
        this.viewer.goToPage(this.viewer.currentPage() + 1)
           }
           else if(e.key==='ArrowLeft'){
      } else if (e.key === 'ArrowLeft') {
        this.viewer.goToPage(this.viewer.currentPage() - 1)
      }
    }
@@ -164,6 +166,7 @@ export default {
.jama-collection-seadragon-wrap {
  position: relative;
  padding-bottom: $paginator-height !important;

  .osd-toolbar {
    width: 100%;
    position: absolute !important;
+9 −3
Original line number Diff line number Diff line
@@ -608,8 +608,9 @@ export default {
    Vue.prototype.$jamaConfirm = this.jamaConfirm

    document.addEventListener('keydown', (e) => {
      if (!this.currentResource)
      if (!this.currentResource || this.promptOptions) {
        return;
      }
      let offset = null;
      switch (e.key) {
        case "ArrowLeft":
@@ -624,9 +625,14 @@ export default {

      if(offset){
        let target = this.resources[this.currentResourceIndex + offset];
        if (target)

        if (target) {
          try {
            document.querySelector('#jama-resource-tile-' + target.id).click();
          }
          catch(e){return false}
        }
      }

    })
  },