开发者

How to prevent user close my application? (Linux Touchscreen apps)

I would like to have an application running in a linux box with a touchscreen monitor. I don't w开发者_JS百科ant to use Flash player (with full window size), so my question is, what I should use instead of a Flash Player?

This box is gonna be in a place with a lot of kids, so they can close the application and shutdown the machine XD.

I'm not a Sr. Java developer, so I don't know if theres something over there to block the 'close window' feature in an java application.

Thanks in advance!


Assuming you're using swing, you could use Frame.setUndecorated(true) and maximize it. There is also the option of exclusive full screen mode. From there, you'll have to unbind any global keys that map to window-exiters/taskmanagers/other-utils.

You may also want a watcher/spawner script setup to make sure your app stays up. I bet there is a more elegant way to do this but most window managers try to avoid an app doing this due to malicious possibilities.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜