Native alert message

Hi, I am trying to display a message to the user to say something like “Confirm Next Turn?” with an OK and Cancel button. I am using the native.showalert call and I have a couple of issues.

  1. The alert shows up on the top left of the screen and isn’t very tidy. Having seen screenshots of the alert in action on tutorial pages where it looks great and in the middle of the screen, is this an issue with the simulator? This would explain why I can’t move it with x and y coordinates

  2. When the alert is on the screen (I am using the simulator on Windows), I can still press buttons on the underlying screen. Is there any way of disabling any game function until the user has pressed one of the alert buttons?

Thanks

Adrian [import]uid: 83824 topic_id: 16207 reply_id: 316207[/import]

you need to run it on an actual device to see what it looks like. The simulator is *no* indicator for the alertBox, therefore it is called the native.showAlert

cheers,

?:slight_smile: [import]uid: 3826 topic_id: 16207 reply_id: 60332[/import]

Thanks JayantV - does that pertain to the second point of freezing the underlying screen too?

Adrian [import]uid: 83824 topic_id: 16207 reply_id: 60345[/import]

When you run it on the native device, it is what is called a *modal* dialog, that means that you cannot do anything till you dismiss that, so you cannot click on any underlying buttons, etc.

cheers,

?:slight_smile: [import]uid: 3826 topic_id: 16207 reply_id: 60347[/import]