Before you begin
You should have the following things ready:
- The BlackBerry Native SDK for Tablet OS
- Your BlackBerry PlayBook tablet
- A basic understanding of the C language and some experience running applications with the BlackBerry Native SDK for Tablet OS
If you need more information, the following topics in the BlackBerry Native SDK for Tablet OS Getting Started Guide might help:
Create your project
To get the Good Citizen application up and running, you need to create the appropriate project:
- In the QNX Momentics IDE, on the File menu, click New > Project.
- Expand Examples and click BlackBerry Tablet OS Example Project. Click Next.
- Select BlackBerry Tablet OS Example Good Citizen Project. Click Next.
- Verify that you'd like to create the project in the default workspace, or clear the Use default location check box and select a different location for the project.
- Click Finish.
The project appears in the Project Explorer window in the IDE. To see the source files in the project, you can expand the project folder and then the src folder.
Using the application
In the Good Citizen example application, users control the color of the cube that appears on the screen by using the color menu. Users can interact with the application by tapping the radio buttons that appear to the left of the text. The current color of the cube is indicated by the radio button that is selected. The radio buttons are displayed using one of two .png files located in the project directory; one file shows a selected button and the other shows an unselected button.
Swipe down from the top of the bezel.
The color menu appears on the screen.
Tap the radio buttons on the screen.
The color of the rotating cube changes and the selected radio button is highlighted.
Tap anywhere outside the radio buttons.
If the color menu is displayed, it will disappear.