Main class (entry point)
PHP Code:
public class Test_01 extends UiApplication
{
static private Test_01 theApp;
private Screen_01 fScreen = null;
public Test_01()
{
fScreen = new Screen_01();
}
public static void main(Stringxxx91;xxx93; args)
{
theApp = new Test_01();
theApp.displayScreen();
theApp.enterEventDispatcher();
}
// ... add any other code you might need here
public void displayScreen()
{
System.out.println("!> showInfo");
// push the screen on top of screen stack:
Ui.getUiEngine().pushGlobalScreen(fScreen, 4, UiEngine.GLOBAL_SHOW_LOWER);
}
}
And now the screen class:
PHP Code:
// you could extend any other Scrren type but i prefer the popup one :)
// feel free to experiment with other types
final public class Screen_01 extends PopupScreen
{
public Screen_01()
{
super(new VerticalFieldManager());
// add other screen fields here.
}
public void sublayout(int width, int height)
{
super.sublayout(width, height);
setExtent(100, 200);
setPosition(10, 20);
}
// and I always prefer to 'disable' theme:
protected void applyTheme()
{
}
}
You need to pop the screen at some time, of course, but you can try to guess that one yourself
Hope I didn't miss anything