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

ClientInfoEvent should preserve the precision of devicePixelRatio

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 9.6.3
    • 9.6.2
    • None
    • Security Level: Jimmy

      Steps to Reproduce

      1. https://github.com/zkoss/zk/blob/ae872065c723727e7b8c121c469fcc95e51b23f3/zk/src/archive/web/js/zk/au.ts#L1379

      Current Result

      it rounds the devicePixelRatio to a single decimal digit: dpr.toFixed(1)

      Expected Result

      no rounding

      Debug Information

      • Some application logic that depends on this ratio can't get the precise value.
      • since ClientInfoEvent.getDevicePixelRatio() returns a double, ZK should keep its precision to double.

            jumperchen jumperchen
            hawk hawk
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: