Mobile popups

How about centering popups in the middle of the current viewing area on mobile devices?

It’s a bit of a pain to realize that that yes, something did happen when you clicked that icon. It just happened off screen and now you have to go find it.

The client has no clue what the current viewing area is. I’m not sure if I can even derive this information from the browser, but I’ll see.

The client does have an idea where the user just poked the screen.
Does the client know what the current zoom factor is?
At a minimum, could the popup be centered on where the poke just happened? (not going beyond the edge of the screen of course)

I think you would want to try something like this.

window = system.nav.openWindow('somewindow')
window.bounds = (event.x,event.y,somewidth,someheight)

This doesnt take in effect the size of the viewport. Any suggestions Carl? To get the size of the main JFrame of a project is easy, however, I dont think it is as easy to get teh size of the view from the vnc side.

Yeah you could pretty easily position the new window relative to the click as Kyle suggested. Still unsure about viewport/zoom information from the browser.

[quote=“Kyle Chase”]I think you would want to try something like this.


That would work for my windows (thanks) but this topic was started because of system type windows like: “Are you sure you want to logout?” eg: system.gui.errorBox() and system.gui.confirm()