public class DropdownSelectionListener
extends SelectionAdapter
Constructor and Description |
---|
DropdownSelectionListener(ToolItem dropdown)
Creates a drop-down handler for a drop-down toolbar item.
|
DropdownSelectionListener(ToolItem dropdown,
boolean lastDefault)
Creates a drop-down handler for a drop-down toolbar item.
|
DropdownSelectionListener(ToolItem dropdown,
SelectionListener select)
Creates a drop-down handler for a drop-down toolbar item.
|
DropdownSelectionListener(ToolItem dropdown,
SelectionListener select,
boolean lastDefault)
Creates a drop-down handler for a drop-down toolbar item.
|
Modifier and Type | Method and Description |
---|---|
MenuItem |
add(String item,
Image image,
int style,
SelectionListener select)
Adds a menu item with a selection listener to the drop-down menu.
|
MenuItem |
add(String item,
Image image,
int style,
SelectionListener select,
boolean isDefault)
Adds a menu item with a selection listener to the drop-down menu.
|
MenuItem |
add(String item,
Image image,
SelectionListener select)
Adds a menu item with a selection listener to the drop-down menu.
|
MenuItem |
add(String item,
Image image,
SelectionListener select,
boolean isDefault)
Adds a menu item with a selection listener to the drop-down menu.
|
MenuItem |
add(String item,
int style,
SelectionListener select)
Adds a menu item with a selection listener to the drop-down menu.
|
MenuItem |
add(String item,
int style,
SelectionListener select,
boolean isDefault)
Adds a menu item with a selection listener to the drop-down menu.
|
MenuItem |
add(String item,
SelectionListener select)
Adds a menu item with a selection listener to the drop-down menu.
|
MenuItem |
add(String item,
SelectionListener select,
boolean isDefault)
Adds a menu item with a selection listener to the drop-down menu.
|
void |
addMenuListener(MenuListener listener)
Adds a menu listener when the menu becomes visible.
|
void |
addSeparator()
Adds a separator line.
|
void |
setDefaultSelected(MenuItem mi)
Sets the default item.
|
void |
widgetSelected(SelectionEvent event)
Process selection.
|
public DropdownSelectionListener(ToolItem dropdown)
dropdown
- The drop-down toolbar item.public DropdownSelectionListener(ToolItem dropdown, boolean lastDefault)
dropdown
- The drop-down toolbar item.lastDefault
- Last item becomes the default one.public DropdownSelectionListener(ToolItem dropdown, SelectionListener select)
dropdown
- The drop-down toolbar item.select
- The selection listener or null for none.public DropdownSelectionListener(ToolItem dropdown, SelectionListener select, boolean lastDefault)
dropdown
- The drop-down toolbar item.select
- The selection listener or null for none.lastDefault
- Last item becomes the default one.public void addMenuListener(MenuListener listener)
listener
- The menu listener.public MenuItem add(String item, SelectionListener select)
item
- The text for the item.select
- The selection listener.public MenuItem add(String item, Image image, SelectionListener select)
item
- The text for the item.image
- The image or null for none.select
- The selection listener.public MenuItem add(String item, int style, SelectionListener select)
item
- The text for the item.style
- The style, a combination of SWT flags, default SWT.NONE.select
- The selection listener.public MenuItem add(String item, Image image, int style, SelectionListener select)
item
- The text for the item.image
- The image or null for none.style
- The style, a combination of SWT flags, default SWT.NONE.select
- The selection listener.public MenuItem add(String item, SelectionListener select, boolean isDefault)
item
- The text for the item.select
- The selection listener.isDefault
- Flag for default selection in the pull-down menu.public MenuItem add(String item, Image image, SelectionListener select, boolean isDefault)
item
- The text for the item.image
- The image or null for none.select
- The selection listener.isDefault
- Flag for default selection in the pull-down menu.public MenuItem add(String item, int style, SelectionListener select, boolean isDefault)
item
- The text for the item.style
- The style, a combination of SWT flags, default SWT.NONE.select
- The selection listener.isDefault
- Flag for default selection in the pull-down menu.public MenuItem add(String item, Image image, int style, SelectionListener select, boolean isDefault)
item
- The text for the item.image
- The image or null for none.style
- The style, a combination of SWT flags, default SWT.NONE.select
- The selection listener.isDefault
- Flag for default selection in the pull-down menu.public void addSeparator()
public void setDefaultSelected(MenuItem mi)
public void widgetSelected(SelectionEvent event)
Phantom® and NetPhantom® are registered trademarks of Mindus SARL.
© © Mindus SARL, 2024. All rights reserved.