public class ToolItemProxy extends ButtonProxy
org.eclipse.swt.widgets.ToolItem
.
GuiTestObject
Role | Interface |
---|---|
radio button | ToggleGUITestObject |
check box | ToggleGUITestObject |
toggle button | ToggleGUITestObject |
push button | GuiTestObject |
push button with drop down | GuiSubitemTestObject |
text | Button Visible Text | ITestDataText |
state | Toggle Button State | ITestData |
Property | Usage |
---|---|
.class | The Java full class name of the test object. |
.classIndex | The zero-based index of the class relative to the immediate parent in the object map. |
text | The visible text of the toolitem. If there is no visible text this property is omitted. |
Subitem | Usage |
---|---|
Location |
Defines the Dropdown arrow on a toolitem. |
ControlProxy.ChildEnumerator, ControlProxy.ImmediateChildEnumerator
childrenEnumerated, CLASSINDEX, CLASSINDEXWEIGHT, clickArgs, currentMethod, GROUPTEXT, GROUPTEXTWEIGHT, HANDLE, MAPPABLECLASSINDEX, MAPPABLECLASSINDEXWEIGHT, MAX_NAME, predownScreenRect, PRIORLABEL, PRIORLABELWEIGHT, TOOLTIPTEXT, TOOLTIPTEXTWEIGHT
LEFT, preDownState, processMouseEventHandler, ROLEINDEX, ROLEINDEXWEIGHT, TESTDATA_SPECIALFRAMESTATE, TESTDATA_SPECIALFRAMESTATE_DESCRIPTION, topLevelWindow
BROWSERTABTESTOBJECT_CLASSNAME, BROWSERTESTOBJECT_CLASSNAME, COLORDIALOGTESTOBJECT_CLASSNAME, CROSSDOMAINCONTAINER_CLASSNAME, DOCUMENTTESTOBJECT_CLASSNAME, DOMAINTESTOBJECT_CLASSNAME, ECLIPSETOPLEVELTESTOBJECT_CLASSNAME, EMBEDDEDBROWSERTESTOBJECT_CLASSNAME, FILEDIALOGTESTOBJECT_CLASSNAME, FRAMESUBITEMTESTOBJECT_CLASSNAME, FRAMETESTOBJECT_CLASSNAME, GEFEDITPARTTESTOBJECT_CLASSNAME, GUISUBITEMTESTOBJECT_CLASSNAME, GUITESTOBJECT_CLASSNAME, INTERNALFRAMETESTOBJECT_CLASSNAME, MESSAGEBOXTESTOBJECT_CLASSNAME, PALETTEGUISUBITEMTESTOBJECT_CLASSNAME, PROCESSTESTOBJECT_CLASSNAME, SCROLLSUBITEMTESTOBJECT_CLASSNAME, SCROLLTESTOBJECT_CLASSNAME, SELECTGUISUBITEMTESTOBJECT_CLASSNAME, SELECTSCROLLGUISUBITEMTESTOBJECT_CLASSNAME, SHELLTESTOBJECT_CLASSNAME, STATELESSGUISUBITEMTESTOBJECT_CLASSNAME, SUBITEMTESTOBJECT_CLASSNAME, TABITEMTESTOBJECT_CLASSNAME, TESTOBJECT_CLASSNAME, TEXTGUISUBITEMTESTOBJECT_CLASSNAME, TEXTGUITESTOBJECT_CLASSNAME, TEXTSCROLLTESTOBJECT_CLASSNAME, TEXTSELECTGUISUBITEMTESTOBJECT_CLASSNAME, TIMEOUTTESTOBJECT_CLASSNAME, TOGGLEGUITESTOBJECT_CLASSNAME, TOGGLETESTOBJECT_CLASSNAME, TOPLEVELSUBITEMTESTOBJECT_CLASSNAME, TOPLEVELTESTOBJECT_CLASSNAME, TRACKBARTESTOBJECT_CLASSNAME, vomClippedRectangle
INCLUDE_ALL, INCLUDE_JUSTOBJECT, INCLUDE_SIBLINGS
Constructor and Description |
---|
ToolItemProxy(java.lang.Object theObjectInTheSUT)
This sole constructor for all proxy objects sets the SUT object
as a member variable for the proxy.
|
Modifier and Type | Method and Description |
---|---|
void |
click(MouseModifiers modifiers,
Subitem subitem)
Perform a mouse click action at the specified object relative
coordinates within the associated TestObject.
|
void |
click(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a mouse click action on the specified coordinates relative
to the associated TestObject.
|
void |
click(Subitem subitem)
Left mouse click on the center point of the associated subitem.
|
void |
click(Subitem subitem,
java.awt.Point pt)
Left mouse click on the specified coordinates relative to the
associated TestObject.
|
void |
doubleClick(MouseModifiers modifiers,
Subitem subitem)
Perform a mouse dbl-click action at the specified object relative
coordinates within the associated TestObject.
|
void |
doubleClick(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a mouse dbl-click action on the specified coordinates relative
to the associated TestObject.
|
void |
doubleClick(Subitem subitem)
Left mouse dbl-click on the center point of the associated TestObject.
|
void |
doubleClick(Subitem subitem,
java.awt.Point pt)
Left mouse dbl-click on the specified coordinates relative to the
associated TestObject.
|
void |
drag(MouseModifiers modifiers,
Subitem subitem)
Perform a drag action against the associated TestObject with the
supplied set of mouse modifiers.
|
void |
drag(MouseModifiers modifiers,
Subitem subitem1,
java.awt.Point pt1,
Subitem subitem2,
java.awt.Point pt2)
Perform a drag action against the associated TestObject.
|
void |
drag(MouseModifiers modifiers,
Subitem subitem1,
Subitem subitem2)
Perform a drag action against the associated TestObject.
|
void |
drag(Subitem subitem)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
drag(Subitem subitem1,
java.awt.Point pt1,
Subitem subitem2,
java.awt.Point pt2)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
drag(Subitem subitem1,
Subitem subitem2)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
dragToScreenPoint(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point screenPt)
Perform a drag action against the associated TestObject.
|
void |
dragToScreenPoint(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point subitemPt,
java.awt.Point screenPt)
Perform a drag action against the associated TestObject.
|
void |
dragToScreenPoint(Subitem subitem,
java.awt.Point screenPt)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
dragToScreenPoint(Subitem subitem,
java.awt.Point subitemPt,
java.awt.Point screenPt)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
IChannel |
getChannel()
return a channel for the object.
|
java.util.Enumeration |
getChildrenEnumeration()
Return an enumeration of proxies for the children
of this object.
|
java.util.Enumeration |
getImmediateChildren()
Return an enumeration of proxies for the children of this object.
|
protected java.lang.String |
getLeadingLabel()
This method is used to generate an interesting descriptive name
for controls without persistent text.
|
ProxyTestObject |
getMappableParent()
Returns a proxy object for the parent of this object.
|
ProxyTestObject[] |
getOwnedObjects()
Return an array of proxies for the objects owned
by this object.
|
ProxyTestObject |
getOwner()
Returns a proxy object for the owner of this object.
|
ProxyTestObject |
getParent()
Returns a proxy object for the parent of this object.
|
java.lang.Object |
getParentObject()
Returns an object for the parent of this object.
|
java.awt.Point |
getScreenPoint(Subitem subitem)
Returns the screen relative point to the center of the supplied
subitem.
|
java.awt.Point |
getScreenPoint(Subitem subitem,
java.awt.Point pt)
Returns the screen relative point given a subitem and a subitem
relative point.
|
java.awt.Rectangle |
getScreenRectangle()
Returns the rectangle that contains the component being
evaluated relative to the top left corner of the screen.
|
java.awt.Rectangle |
getScreenRectangle(Subitem subitem)
Returns the rectangle that contains the component being
evaluated relative to the top left corner of the screen.
|
protected int |
getStyle() |
java.lang.Object |
getSubitem(Subitem subitem)
Returns an object that represents the specified subitem in the associated
test object.
|
java.lang.String |
getTestObjectClassName()
Return the test object.
|
ProxyTestObject |
getTopMappableParent()
Returns a proxy object for the top parent of this object.
|
ProxyTestObject |
getTopParent()
Returns a proxy object for the top parent of this object.
|
void |
hover(double secondDelay,
Subitem subitem)
Hover the mouse over the center of the specified subitem.
|
void |
hover(double secondDelay,
Subitem subitem,
java.awt.Point pt)
Hover the mouse over the specified coordinates relative to the
specified subitem.
|
void |
hover(Subitem subitem)
Hover the mouse over the center of the specified subitem.
|
void |
hover(Subitem subitem,
java.awt.Point pt)
Hover the mouse over the specified coordinates relative to the
specified subitem.
|
boolean |
isEnabled()
Check the component under evaluation to determine if it is
enabled or disabled.
|
boolean |
isPointInObject(java.awt.Point pt)
Determines if the specified screen relative point is
contained in the component under evaluation.
|
boolean |
isShowing()
Check the component under evaluation to determine if it is
showing (as apposed to hidden).
|
void |
mouseMove(MouseModifiers modifiers,
Subitem subitem)
Perform a move action against the associated TestObject.
|
void |
mouseMove(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a move action against the associated TestObject.
|
void |
mouseMove(Subitem subitem)
Perform a MOUSE_LEFT move action against the associated TestObject.
|
void |
mouseMove(Subitem subitem,
java.awt.Point subitemPt)
Perform a MOUSE_LEFT move action against the associated TestObject.
|
void |
nClick(int clickCount,
MouseModifiers modifiers,
java.awt.Point pt)
Perform a mouse n-click action on the specified coordinates relative
to the associated TestObject.
|
void |
nClick(int clickCount,
MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a mouse n-click action on the specified coordinates relative
to the associated TestObject.
|
void |
nClickDrag(int clickCount,
MouseModifiers modifiers,
Subitem subitem1,
java.awt.Point pt1,
Subitem subitem2,
java.awt.Point pt2)
Perform a mouse n-click drag action on the specified coordinates relative
to the associated TestObject.
|
void |
nClickDrag(int clickCount,
MouseModifiers modifiers,
Subitem subitem1,
Subitem subitem2)
Perform a mouse n-click drag action on the specified coordinates relative
to the associated TestObject.
|
void |
nClickDragToScreenPoint(int clickCount,
MouseModifiers modifiers,
Subitem subitem,
java.awt.Point screenPt)
Perform a mouse n-click drag action on the specified coordinates relative
the screen relative screenPt coordinates.
|
void |
nClickDragToScreenPoint(int clickCount,
MouseModifiers modifiers,
Subitem subitem,
java.awt.Point subitemPt,
java.awt.Point screenPt)
Perform a mouse n-click drag action on the specified coordinates relative
the screen relative screenPt coordinates.
|
clickToState, clickToState, deselect, dragToState, dragToState, getDescriptiveName, getLabel, getMethodSpecForPoint, getProperty, getRole, getState, getTestData, getTestDataTypes, getUniqueId, indeterminate, processSingleMouseEvent, select, setState, updateTestData
childConstructed, getActionArgs, getChildProxy, getClippedScreenRectangle, getDefaultActionArgs, getElementWithFocus, getHandle, getLabelText, getLocationOnScreen, getName, getReorderedChildren, getToolTipText, getVisualClippedRectangle, hasFocus, isGTK, isLabelled, isObjectMoved, isShell, processHoverMouseEvent, processPreDownMouseEvent, processPreUpMouseEvent, scrollRectToVisible, setClickArgs, setDownPointArgs, setDrag, setMethodSpecification, setMultiClickAction, setRecordCache
activateTopWindow, click, doubleClick, drag, dragToScreenPoint, dumpAction, ensureObjectIsVisible, getActionRect, getCachedRectX, getCachedRectY, getChildAtPoint, getClippedRect, getProcessMouseEventHandler, getRegisteredTopLevelWindow, getScreenPoint, getScriptCommandFlags, getTopMappableWindow, getTopWindow, hover, invokeMethodOnEDT, isDrag, isOpaque, isPointInObject, modifiersChanged, processMouseEvent, setProcessMouseEventHandler, setTopLevelWindow, shouldBeMapped
addMappableChildrenToVector, addRecognitionProperty, allowProperty, getAddedRecognitionPropertyValue, getChildren, getIndexer, getIndexers, getMappableChildren, getMethods, getNonValueProperties, getProperties, getRecognitionProperties, getRecognitionPropertyWeight, getStandardProperties, getTestDomain, getVisualClippableParent, hasAddedRecognitionProperties, isRecognitionProperty, setIndexer, setProperty
addDataDrivableCommands, baseClassMatch, canTakeVP, equals, findChildrenWithProperties, findChildrenWithPropertiesAndInvoke, getChildren, getDataDrivableCommand, getDataDrivableCommands, getField, getIgnorableProperties, getMappableChildren, getMappableParent, getObjectClassName, getObjectCustomClassName, getOwnedObjects, getParent, getProxy, getScriptCommandAnchor, getVisualMappableChildren, getVisualTopParent, getVOMSpecificProperty, hasSpecialFrameState, isClassIndexConsidered, isSameObject, isValidObject, ping, suppressKeyAction
public ToolItemProxy(java.lang.Object theObjectInTheSUT)
public java.lang.String getTestObjectClassName()
getTestObjectClassName
in interface IProxyBase
getTestObjectClassName
in class ButtonProxy
public boolean isShowing()
isShowing
in class ControlProxy
public boolean isEnabled()
isEnabled
in class ControlProxy
protected int getStyle()
getStyle
in class ControlProxy
public ProxyTestObject getParent()
getParent
in class ControlProxy
public ProxyTestObject getMappableParent()
getMappableParent
in class ControlProxy
public ProxyTestObject getTopParent()
getTopParent
in class ControlProxy
public ProxyTestObject getTopMappableParent()
getTopMappableParent
in class ControlProxy
public java.lang.Object getParentObject()
getParentObject
in class ControlProxy
public java.util.Enumeration getChildrenEnumeration()
getChildrenEnumeration
in class ControlProxy
public java.util.Enumeration getImmediateChildren()
getImmediateChildren
in class ControlProxy
public ProxyTestObject getOwner()
getOwner
in class ControlProxy
public ProxyTestObject[] getOwnedObjects()
getOwnedObjects
in class ControlProxy
protected java.lang.String getLeadingLabel()
getLeadingLabel
in class ControlProxy
public boolean isPointInObject(java.awt.Point pt)
This functionality is performed by the proxy due to potentially
unusual aspects associated with functionality. While typically
the getScreenRectangle
is
used to resolve this query, there are situations for which this
is not accurate. For instance if the clickable region on a
button is not rectangular, just checking if the point is in
the rectangle is not be valid.
isPointInObject
in class JavaGuiProxy
pt
- Screen relative point to check.getScreenRectangle()
public IChannel getChannel()
getChannel
in class ControlProxy
public java.awt.Rectangle getScreenRectangle()
getScreenRectangle
in class ControlProxy
public java.awt.Rectangle getScreenRectangle(Subitem subitem)
public java.awt.Point getScreenPoint(Subitem subitem)
getScreenPoint
in class JavaGuiProxy
subitem
- The subitem the resultant screen point is
relative to.public java.awt.Point getScreenPoint(Subitem subitem, java.awt.Point pt)
subitem
- The subitem the resultant screen point is
relative to.pt
- The subitem relative point.public java.lang.Object getSubitem(Subitem subitem)
SubitemNotFoundException
will be thrown if the specified subitem is invalid relative to the associated
test object. null
may be returned if the subitem does not have
an object association that can be returned.subitem
- The subitem to fetch an object for.public void nClick(int clickCount, MouseModifiers modifiers, java.awt.Point pt)
nClick
in class JavaGuiProxy
public void click(Subitem subitem)
click
in class JavaGuiProxy
public void click(MouseModifiers modifiers, Subitem subitem)
click
in class JavaGuiProxy
public void click(Subitem subitem, java.awt.Point pt)
click
in class JavaGuiProxy
public void click(MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void doubleClick(Subitem subitem)
doubleClick
in class JavaGuiProxy
public void doubleClick(MouseModifiers modifiers, Subitem subitem)
doubleClick
in class JavaGuiProxy
public void doubleClick(Subitem subitem, java.awt.Point pt)
doubleClick
in class JavaGuiProxy
public void doubleClick(MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void nClick(int clickCount, MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void drag(Subitem subitem)
drag
in class JavaGuiProxy
public void drag(MouseModifiers modifiers, Subitem subitem)
drag
in class JavaGuiProxy
public void drag(Subitem subitem1, Subitem subitem2)
drag
in class JavaGuiProxy
public void drag(MouseModifiers modifiers, Subitem subitem1, Subitem subitem2)
drag
in class JavaGuiProxy
public void drag(Subitem subitem1, java.awt.Point pt1, Subitem subitem2, java.awt.Point pt2)
public void drag(MouseModifiers modifiers, Subitem subitem1, java.awt.Point pt1, Subitem subitem2, java.awt.Point pt2)
public void nClickDrag(int clickCount, MouseModifiers modifiers, Subitem subitem1, Subitem subitem2)
nClickDrag
in class JavaGuiProxy
public void nClickDrag(int clickCount, MouseModifiers modifiers, Subitem subitem1, java.awt.Point pt1, Subitem subitem2, java.awt.Point pt2)
public void dragToScreenPoint(Subitem subitem, java.awt.Point screenPt)
dragToScreenPoint
in class JavaGuiProxy
public void dragToScreenPoint(MouseModifiers modifiers, Subitem subitem, java.awt.Point screenPt)
dragToScreenPoint
in class JavaGuiProxy
public void dragToScreenPoint(Subitem subitem, java.awt.Point subitemPt, java.awt.Point screenPt)
dragToScreenPoint
in class JavaGuiProxy
public void dragToScreenPoint(MouseModifiers modifiers, Subitem subitem, java.awt.Point subitemPt, java.awt.Point screenPt)
public void nClickDragToScreenPoint(int clickCount, MouseModifiers modifiers, Subitem subitem, java.awt.Point screenPt)
nClickDragToScreenPoint
in class JavaGuiProxy
public void nClickDragToScreenPoint(int clickCount, MouseModifiers modifiers, Subitem subitem, java.awt.Point subitemPt, java.awt.Point screenPt)
public void mouseMove(Subitem subitem)
mouseMove
in class JavaGuiProxy
public void mouseMove(Subitem subitem, java.awt.Point subitemPt)
mouseMove
in class JavaGuiProxy
public void mouseMove(MouseModifiers modifiers, Subitem subitem)
mouseMove
in class JavaGuiProxy
public void mouseMove(MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void hover(double secondDelay, Subitem subitem)
hover
in class JavaGuiProxy
public void hover(double secondDelay, Subitem subitem, java.awt.Point pt)
public void hover(Subitem subitem)
hover
in class JavaGuiProxy
public void hover(Subitem subitem, java.awt.Point pt)
hover
in class JavaGuiProxy