Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-3658

Listbox invalidates the whole widget instead of the items

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Done
    • Icon: Critical Critical
    • 9.0.0
    • 8.0.5
    • None
    • Security Level: Jimmy
    • None
    • ZK 8.5.2 S1, ZK 8.6.0 S1, ZK 8.6.0 S2, ZK 9.0.0 S0, ZK 9.0.0 S1
    • None

      Feature:

      Listbox workflow can be improved to only invalidate the listitems when performing model operations.

      Details:

      When performing model operations, bulk removing or adding items, performing paging operations, etc the listbox component triggers invalidate on the whole listbox widget.

      The grid component only invalidates the <rows> child of the grid only:
      https://github.com/zkoss/zk/blob/884e074c3ab999798dcf38b01564ec1f4c940818/zul/src/org/zkoss/zul/Grid.java#L621
      https://github.com/zkoss/zk/blob/6c0b7d060024e6b07fa75b9c904ed2f98d2bff2e/zul/src/org/zkoss/zul/impl/GridDataLoader.java#L113
      https://github.com/zkoss/zk/blob/6c0b7d060024e6b07fa75b9c904ed2f98d2bff2e/zul/src/org/zkoss/zul/impl/GridDataLoader.java#L145

      This prevent headers content from being redrawn on every model operation. Since a common usecase for headers is to hold filter textboxes, the full listbox invalidation causes text to disappear from these textbox if the user write in while a model update is performed.

            rudyhuang rudyhuang
            MDuchemin MDuchemin
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 1 week Original Estimate - 1 week
                1w
                Remaining:
                Time Spent - 1 week Remaining Estimate - 1 day, 7 hours
                1d 7h
                Logged:
                Time Spent - 1 week Remaining Estimate - 1 day, 7 hours
                1w