简体   繁体   中英

Eclipse RCP. Java. Create new window

In the main window (which appears after starting the application), I have to make the main menu, it should have a window section, in this section I should select the new window, and after clicking on the new window I should have a new window, and such windows I can create no more than two. (that is, window-> new window)

In the Internet I could not find anything sensible on my question. Prompt how to create new windows (not tabs in a window, namely a new window !!!) in Eclipse RCP or give useful links and even better examples?

And tell me if there is any GUI in Eclipse RCP at all? Or are all the elements added to the window programmatically?

For a 3.x compatibility mode RCP use:

PlatformUI.getWorkbench().openWorkbenchWindow(perspectiveId, input);

perspectiveId is the id of the perspective you want the new window to use.

input is any IAdaptable you want the window to use as its initial input or null for no input. A common input is the workspace root: ResourcesPlugin.getWorkspace().getRoot() .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM