Uploaded image for project: 'ZK Spreadsheet'
  1. ZK Spreadsheet
  2. ZSS-1350

When Spreadsheet gets the focus, it scroll the whole page up

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 3.9.5
    • 3.9.2
    • None
    • Security Level: Jimmy
    • None
    • Sprint 8

      Steps to Reproduce

      1. load t5183.zul
      a big block area on top of a spreadsheet and produces vertical scrollbar.
      2. scroll down the whole page to see the complete spreadsheet
      3. click a cell

      alternative Steps to Reproduce

      1. load t5183.zul
      2. scroll down the whole page to see the complete spreadsheet
      3. click A1
      4. do step 2 again
      5. double click A2

      Current Result

      the browser scrolls up the whole page to the top

      Expected Result

      no scroll up

      root cause

      selectFocustag: function () {
          ....
          inlineEditor.getInputNode().focus();
      }
      

      inlineEditor.getInputNode() is always on the left-top corner of the page, so focus it will scroll the whole page up.

      Solution

      remove focus(). Since select the whole text already can allow direct edit without entering edit mode.

      Workaround

      zss-1350.js

        1. t5183.zul
          0.3 kB
        2. zss-1350.js
          0.4 kB

            hawk hawk
            hawk hawk
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: