How to open multiple workbench windows? [message #1016858] |
Thu, 07 March 2013 17:44  |
Eclipse User |
|
|
|
Hi all,
is it still possible to open different windows (pages?) in E4 from a single Workbench? So I don'T talk about additional editors or views, but full Workbench windows. I've a fairly complex UI built with different PartSashContainers, PartStacks and Parts building an associated set of parts for my new RCP app. Now I need to open this full set of parts multiple times, one for each file the users wants to work with (if the user opens three files, this full set has to be shown three times, one per workbench window each). I could restart the full workbench three times, but there must be a more elegant way. Using complex editor parts seem's not to be a good solution either, since I'd lose the flexibility of user-arranged tabs and subwindows then. To hold everthing together, I'm thinking about a launcher object with main menu, if the product starts without file.
I've googled around a few hours, but only find 3.x samples using the PlatformUI.getWorkbench().openWorkbenchWindow(...) way. Since PlatformUI is no longer part of E4, I maybe just don't know what object to inject to get a similar functionality. While there are different samples available using EPartService to clone parts and switch Perspectives, I don't feel to be able to open additional Workbench windows this way (Q: To find the Workbench object, what search string/id do I have to use?)
Thanks in advance,
Guido
|
|
|
Re: How to open multiple workbench windows? [message #1021930 is a reply to message #1016858] |
Wed, 20 March 2013 20:09   |
Eclipse User |
|
|
|
Hi Guido,
I think you can use the EModelService. Experiment with findElements and
Cloneelement.
Best regards,
Wim
> Hi all,
>
> is it still possible to open different windows (pages?) in E4 from a single
Workbench? So I don'T talk about additional editors or views, but full
Workbench windows. I've a fairly complex UI built with different
PartSashContainers, PartStacks and Parts building an associated set of parts
for my new RCP app. Now I need to open this full set of parts multiple times,
one for each file the users wants to work with (if the user opens three
files, this full set has to be shown three times, one per workbench window
each). I could restart the full workbench three times, but there must be a
more elegant way. Using complex editor parts seem's not to be a good solution
either, since I'd lose the flexibility of user-arranged tabs and subwindows
then. To hold everthing together, I'm thinking about a launcher object with
main menu, if the product starts without file.
>
> I've googled around a few hours, but only find 3.x samples using the
PlatformUI.getWorkbench().openWorkbenchWindow(...) way. Since PlatformUI is
no longer part of E4, I maybe just don't know what object to inject to get a
similar functionality. While there are different samples available using
EPartService to clone parts and switch Perspectives, I don't feel to be able
to open additional Workbench windows this way (Q: To find the Workbench
object, what search string/id do I have to use?)
>
> Thanks in advance,
> Guido
|
|
|
|
Re: Re: How to open multiple workbench windows? [message #1022739 is a reply to message #1022642] |
Fri, 22 March 2013 08:56  |
Eclipse User |
|
|
|
Hi Guido,
> thank you very much! The following code works for me (as a first test). A
new workbench window is opened on exactly the same position of the old:
Great. You can use the model to alter the positions of the window.
> P.S. Are you the same Wim from Netherlands sitting in back of my class held
by Lars in Berlin last autumn?
Yes I am. Glad to see you working on e4.
Best regards,
Wim
|
|
|
Powered by
FUDForum. Page generated in 0.04025 seconds