org.eclipse.gmf.runtime.diagram.ui.properties.sections.appearance
Class LineStylesPopup
java.lang.Object
org.eclipse.gmf.runtime.diagram.ui.properties.sections.appearance.LineStylesPopup
-
Direct Known Subclasses:
-
ArrowTypePopup,
LineTypePopup,
LineWidthPopup
-
public abstract class LineStylesPopup
- extends java.lang.Object
The menu-like pop-up widget that allows the user to select a value for the line styles.
-
Since:
- 2.1
Constructor Summary
|
LineStylesPopup
(
Shell parent)
Creates a LineStylesPopup below the specified shell. |
Method Summary
|
java.lang.Object
|
getSelectedItem
()
Gets the item the user selected. |
protected abstract void
|
initializeImageMap
()
Initialize the image map by adding items and images to the imageMap. |
void
|
open
(
Point location)
Open the popup, waits for an item to be selected and then closes popup. |
void
|
open
(
Point location,
int lowerY)
Opens the popup ensuring that it doesn't run of the screen and doesn't
hide the launching button |
Methods inherited from class java.lang.Object
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
|
imageMap
protected java.util.Map imageMap
- The map of items in the popup. The key is the return value of the popup
and the value in the map is the image.
shell
protected
Shell shell
selectedItem
protected java.lang.Object selectedItem
LineStylesPopup
public LineStylesPopup(
Shell parent)
- Creates a LineStylesPopup below the specified shell.
-
Parameters:
-
parent
- a widget which will be the parent of the new instance (cannot
be null)
initializeImageMap
protected abstract void initializeImageMap()
- Initialize the image map by adding items and images to the imageMap.
-
open
public void open(
Point location)
- Open the popup, waits for an item to be selected and then closes popup.
-
-
Parameters:
-
location
- the initial location of the popup; the popup will be
positioned so that it does not run off the screen and the
largest number of items are visible
open
public void open(
Point location,
int lowerY)
- Opens the popup ensuring that it doesn't run of the screen and doesn't
hide the launching button
-
-
Parameters:
-
location
- the initial location of the popup -
lowerY
- if the final y is above location.y, then the popup is moved
above lowerY -
Since:
- 1.2
getSelectedItem
public java.lang.Object getSelectedItem()
- Gets the item the user selected. Could be null as the user may cancel the
gesture.
-
-
Returns:
- the selected item or null.
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp., Borland Software Corp., and others 2005,2006. All rights reserved.