Thank you for visiting the BlackBerry Support Community Forums.
BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)
BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.
"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."
- Kevin Michaluk, Founder, CrackBerry.com
Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.
02-06-2013 03:09 PM
Is there a way to get the width and height of the current screen in QML?
Because I have to use the absolute layout and I also want to let the position of controller could fit with different dimension of screens, I plan to calculate the position based on the screen size to locate the controller to a relative position. In BB7 development, it is availabe to do this way. But I have not found how to realize it in BB10 QML.
Thank you someone can figure it out.
Solved! Go to Solution.
02-06-2013 03:40 PM - edited 02-06-2013 03:43 PM
Another option is to attach LayoutUpdateHandler to a container and reposition controls on updates. This way screen rotation won't break the layout.
02-06-2013 04:21 PM
LayoutUpdateHandler is very useful. I can finally realize the complicated UI by that. If this methodology could be mentioned in the official documentation, i think that it will help the developers a lot.
02-06-2013 04:37 PM
very simple example .
import bb.cascades 1.0