Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Using CoolbarManager and ToolbarManger on a Shell
Using CoolbarManager and ToolbarManger on a Shell [message #444146] Thu, 07 October 2004 17:24
conor is currently offline conorFriend
Messages: 2
Registered: July 2009
Junior Member
Hi everyone,

I am trying to create Coolbars that I can dynamically add and remove
coolitems from. I started by using CoolBars and CoolItems with Toolbars
in them. I could not find any way of adding or removing easily with
this method. I then tried to follow an example using CoolbarManager and
ToolbarManager which was on an ApplicationWindow. It works fine on the
ApplicationWindow but I need it to be on a simple shell because I am
using eadfrith.org MDI Shell. When I tried it on the simple shell the
toolbars would not appear.

Here is a sample snippet of what I was trying:

_coolMgr = new CoolBarManager(SWT.FLAT);
_coolMgr.createControl(_shell);

ToolBarManager toolBar1 = new ToolBarManager(getMainToolBar());
toolBar1.createControl(_coolMgr.getControl());
_item = new ToolBarContributionItem(toolBar1);

_coolMgr.add(_item);
_item.fill(_coolMgr.getControl(), 1);


I found it very hard to get any documentation for the CoolbarManager and
ToolbarManager apart from the API docs. Does anyone know if I can use
CoolbarManager and ToolbarManager on a normal shell or is it only on
ApplicationWindow that they will work? Also does anyone have any good
examples of how to use them?

Thanks a lot in advance,
Conor.
Previous Topic:Modal dialogs in OLE controls and infopops
Next Topic:Bug 72320: SWT Fails to load ActiveX control with error -2147467262
Goto Forum:
  


Current Time: Thu Oct 22 18:59:38 GMT 2020

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

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

Back to the top