Hello all i want to control on pushing the screen globally from background application. currently i made a Screen which is extending MainScreen. I want to show this screen globally. I am using
pushGlobalScreen(Screen to push, int priority, flag); its working if there is two screen it showing one after other. But what i want to do actually is. I want to close the first screen then i want to show the next screen and so on . So how to achieve this.
Here i am explaining it more clearly
I am explaining the whole scenario I am checking in the database for the time if current time matches with the alarm time then it pushes the screen let suppose there is more than one alarm is saved for the same time.
while (Checking into database for time){
if (databasetime == current time ) {// let suppose there is more than
//one alarm save for the same time
synchronized (getEventLock()) {// This will call one after other but i want to first
UiEngine ui = Ui.getUiEngine();
ui.pushGlobalScreen(new AlarmScreen() , 1, UiEngine.GLOBAL_QUEUE);//
//Here i want to stop. I want user to close the screen then
// i want to push again the screen. As we do in
// PushModalScreen(Screen) How can i block
//pushGlobalScreen(new AlarmScreen() , 1, UiEngine.GLOBAL_QUEUE);
}
}
}
I think my requirement is clear now. is it??
I have solved the issue but in different way. The way i have choosed is, I am storing all the id in the table and checking if there is any id in the table i am pushing only one screen. And before closing it i am checking if there is more id in the table just
updating the Contents of the Screen. Now it is working just as the way i wanted, and if there is no more data i am just closing the screen.