Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Switch to another window
Switch to another window [message #638943] Sat, 13 November 2010 16:37 Go to next message
No real name is currently offline No real nameFriend
Messages: 5
Registered: November 2010
Junior Member
Can anybody tell me how to go to a separate window after clicking a command on a toolbar
Thank you
Re: Switch to another window [message #639244 is a reply to message #638943] Mon, 15 November 2010 17:49 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

gayanlggd@gmail.com wrote:
> Can anybody tell me how to go to a separate window after clicking a
> command on a toolbar

What kind of window? For a workbench window, you could try
workbenchWindow.getShell().setActive()

PW



--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Expression_Framework
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .platform.doc.isv/guide/workbench.htm


Re: Switch to another window [message #639396 is a reply to message #638943] Tue, 16 November 2010 11:59 Go to previous message
Alexandra Niculai is currently offline Alexandra NiculaiFriend
Messages: 84
Registered: July 2009
Member
You mean something like:

IWorkbenchPage page = HandlerUtil.getActiveWorkbenchWindow(event).getActivePage();
page.showView(My.ID, secondaryViewId,IWorkbenchPage.VIEW_ACTIVATE);

?

You can call this code in the handler of your command.

Alexandra.
Previous Topic:How to deactivate IStartup programmatically
Next Topic:run-once initialization of a plug-in on first launch
Goto Forum:
  


Current Time: Fri Apr 19 00:36:35 GMT 2024

Powered by FUDForum. Page generated in 0.02553 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top