开发者

Java external display connected callback?

开发者 https://www.devze.com 2023-01-04 22:43 出处:网络
I\'m writing a presentation app which is supposed to present on the 2nd display in extended mode. For that I want to have a \"Start presentation\" button which reflects the actual state of external d

I'm writing a presentation app which is supposed to present on the 2nd display in extended mode.

For that I want to have a "Start presentation" button which reflects the actual state of external display connections: it should be gray and non-clickable if no external displays are connected. And it should be enabled if there is at least 开发者_JAVA技巧one connected.

I have seen the GraphicsEnvironment class but it only has getXXX methods. It's inefficient because I will have to check the state every few seconds and the state updates not immediately.

Is there a callback method on display connection or something like that for this purpose?

Thanks

Shuo

0

精彩评论

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