Page 1 of 1
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Tue Aug 06, 2013 11:02 pm
by Diego Esteban Osorio Zaldivia
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
In Android I could remove the activities from stack in which the screens are stacked, but here I do not know how.
I want to do this because I have 2 screens of settings and when you get to the third, the user can work. But if user is in the third screen and hit the "back button", shouldn't longer show the settings screens but simply leave.
Thanks in advance.
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Tue Aug 06, 2013 11:08 pm
by Diego Esteban Osorio Zaldivia
I would also like that if the user closes the application and even restarted the phone, and then re-open the application, not shown the config screens again and only sent to the third screen.
Do you know if I can handle this just using LocalStorage, or closing the application and / or restart the phone erases data stored in LocalStorage?
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Tue Aug 06, 2013 11:35 pm
by maxkatz
Are you creating a mobile web app or a hybrid app (PhoneGap)?
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Wed Aug 07, 2013 12:43 am
by Diego Esteban Osorio Zaldivia
mobile app, for use in smartphones with android or other OS
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Wed Aug 07, 2013 1:06 am
by maxkatz
For Android, there is a 'backbutton' event that you can use to do something. Check PhoneGap docs, it might work for other platforms as well.
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Wed Aug 07, 2013 2:45 am
by Diego Esteban Osorio Zaldivia
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Wed Aug 07, 2013 2:46 am
by Diego Esteban Osorio Zaldivia
How I can do so that pressing the "back button" in the telephone doesn't return to the previous page?
Posted: Wed Aug 07, 2013 2:52 am
by maxkatz
I think there is an event that is fired when the app launches (check PhoneGap events). If such event exists, you could use that.
Local storage is just a storage -- you can use it for really anything. Local storage is not erased even if you restart the phone. It's standard browser API: https://developer.mozilla.org/en-US/d...