Search code examples
androidblackberry-10

android - BB10 compatibility


I am newbie to convert android apps to bb10. I converted one app to bb10 compatibility. The app is compatible with both device and tablet in android.I successfully run it in bb10 simulator. But the app doesn't show the UI part completely. Why? I have one more doubt generally BB10 devices shape is rectangle but simulator shape is square. why?

BlackBerry Image BB10

Android Image

Android Image


Solution

  • That is because your UI needs more space than the resolution provides. If you would place your controls within a scrollable container, you would be able to scroll down to the missing parts of your UI.
    If you choose that container to automatically show the scrollbar, this would only be seen on Q10 but not on Z10. Try to switch your simulator to Z10 resolution, then it will propably show all your UI elements.

    The real solution would be really to define the UI in relation to the resolution.

    To start with this, here is an excellent definition on how to cluster your layout resources for your Android app. Your problem will disappear, when defining an appropriate layout for the minimum height(!) of e.g. 600dp and one for 800dp. The one with 600dp will be used for the Q10 (because it has 720px physical height) and the other one for the Z10 (that has 1280px).

    By the way: you should encounter the same problem on some Android device, since there are a few with nearly square display (I remember a "BlackBerry clone" by HTC?). But of cause, these devices are really rare...