Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » SWTBot » Toolbar with Dropdown Items via ExtensionPoint
Toolbar with Dropdown Items via ExtensionPoint [message #777985] Wed, 11 January 2012 08:52
Dominik Missing name is currently offline Dominik Missing nameFriend
Messages: 7
Registered: November 2010
Junior Member

I have created a Dropdown-Toolbar using the Extension-Points of the Plugin.

Now in my test I try to click on a menu-item via
1: SWTWorkbenchBot bot= new SWTWorkbenchBot();
2: SWTBotToolbarDropDownButton toolbarDropDownButton = bot.toolbarDropDownButton("Convert");
3: toolbarDropDownButton.menuItem("to Analog").click();
4: bot.sleep(5000);

and get a WidgetNotFoundException at line 3:

In the end, the bot has not opened the dropDownMenu.
So I understand, that he canĀ“t find the MenuItem.
My question is, why the bot does not expand/open the dropDownMenu.
If I create the DropDownToolbar programmatically (not as a Extension-Point), it works fine.

Has anyone an idea, what I am doing wrong?


I am working with SWTBot 2.0.5
and the
plugin.xml looks like this:
<extension point="org.eclipse.ui.menus">
<menuContribution locationURI="toolbar:de.industronic.configtool.stations.view.edit">
<command commandId="de.industronic.configtool.stations.convert.station" label="Convert" style="pulldown">

<command commandId="de.industronic.configtool.stations.convert.station" label="to Analog" style="push">
<parameter name="de.industronic.configtool.stations.convert.totype" value="analog">
<command commandId="de.industronic.configtool.stations.convert.station" label="to Digital" style="push">
<parameter name="de.industronic.configtool.stations.convert.totype" value="digital">
Previous Topic:ComboBox in Popup window
Next Topic:Using EclipseSpy View location to find widgets
Goto Forum:

Current Time: Thu Apr 19 09:57:55 GMT 2018

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

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