开发者

Is it possible make all JFrames the internal program uses into JInternalFrames and place them in a JDesktopPane?

开发者 https://www.devze.com 2023-01-23 05:27 出处:网络
The goal is to have the user select a java program, then my program opens up a JInternalFramewith a JEditorPane inside it as the console and places said JInternalFrame in a JDeskopPane. Is it possible

The goal is to have the user select a java program, then my program opens up a JInternalFrame with a JEditorPane inside it as the console and places said JInternalFrame in a JDeskopPane. Is it possible to change all the Windows the user's program may open into JInternalFrames and place them in said JDesktopPane, as well?

(individual开发者_JAVA技巧 question from IDE-Style program running)


I'm quite sure that this would not be possible to do without tampering with the binaries of the program that you're launching. If the target program performs something like new Window().show(), you'll have little possibilities to "hook into" the system, and tell it to swap it for a JInternalFrame.

What I'm saying is that if the program is written and compiled to show a top-level window, there is little you could do to change that. There is no "hook" into the system, with which you can say "put all future Windows into this JInternalFrame.

0

精彩评论

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