Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Developer
Posts: 1,230
Registered: ‎03-20-2011
My Device: Playbook, Z10 LE, Dev Alpha B, 2x Dev Alpha C
My Carrier: 3, Orange, Vodafone

Z30 Simulator choice is the wrong size

Choosing the 720x1280 (Z30) option in the latest simulator gets rather frustrating results from window.innerWidth / window.innerHeight

 

The simulator reckons the screen is 719x1279, i.e. one pixel out horizontally + vertically

 

This is frustrating as I'm gonna have to set up a deliberately wrong config for a Sim30 to test layout

 

Fortunately this only takes about 30 seconds to do in my case as I always design to fit anything (copy an XML file and lie about the size)

 

The one pixel probably wont affect most people for for those of us like me who place everything where its meant to be that one pixel makes all the difference




Click the like button if you find my posts useful!
Retired
Posts: 856
Registered: ‎07-15-2008
My Device: Passport
My Carrier: Bell

Re: Z30 Simulator choice is the wrong size

I can reproduce this. It may be a problem with the scaling of the display. Can you open an issue with the issue tracker? The sim team will need to take a look I think.

Tim Windsor
Open Source Technical Lead
Developer
Posts: 1,230
Registered: ‎03-20-2011
My Device: Playbook, Z10 LE, Dev Alpha B, 2x Dev Alpha C
My Carrier: 3, Orange, Vodafone

Re: Z30 Simulator choice is the wrong size

Hi Tim

 

Over the w/e I confirmed that this is a WW issue

 

I added ScreenDisplay to the project build and find that it reports the screen as 720x1280 while JS reports 719x1179 - i.e. the native API in the Sim knows the right size but JS don't

 

This problem also breaks bbui.js (major issue...)

 

I then modified bbui.js to use the values returned by ScreenDisplay - everything happy

 

Finally found the Issue Tracker (it's not that easy to find) so will report it

 




Click the like button if you find my posts useful!