Opened 6 years ago

Closed 4 years ago

#16578 closed defect (invalid)

getScreenSize() returns wrong height in BlackBerry WebWorks application

Reported by: Eric Durocher Owned by: Eric Durocher
Priority: undecided Milestone: tbd
Component: DojoX Mobile Version: 1.8.3
Keywords: Cc: mimendoza
Blocked By: Blocking:


This is a know problem in BlackBerry WebWorks, see for example here:

Can be reproduced on any test using a ScrollableView and packaged as a WebWorks app. The problem appears when you rotate to landscape and back to portrait, and also when editing text once the keyboard goes away. The view appears smaller (in height) than the screen size.

The properties that we normally use ( or win.doc.documentElement.clientHeight) all return inconsistent results. The only thing that works in screen.height, but this must be corrected by the devicePixelRatio, which unfortunately is also wrong in WebWorks (always 1).

A workaround could be to use screen.height and correct it using a ratio computed at startup (where innerHeight seems correct).

This also implies to modify the dojox/mobile code where the screen height is retrieved directly through innerHeight or similar, instead of going through getScreenSize().

Change History (4)

comment:1 Changed 6 years ago by cjolif

Cc: mimendoza added

comment:2 Changed 6 years ago by Patrick Ruzand

Owner: changed from Eric Durocher to Patrick Ruzand
Status: newassigned

comment:3 Changed 4 years ago by dylan

Owner: changed from Patrick Ruzand to Eric Durocher
Status: assignedpending

Given how much WebWorks? has changed, and how few people are using WebWorks? unfortunately, I'm inclined to close this out. Setting to pending, please reopen within 2 weeks if you think this is still relevant.

comment:4 Changed 4 years ago by trac-o-bot

Resolution: invalid
Status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Note: See TracTickets for help on using tickets.