LabelWithButton

Description

Class for buttons that are associated with a static label. Offers same interactions as Button.

LabelWithButton Class

Namespace: Progile.TRIO.BaseModel Assembly: Progile.TRIO.BaseModel (in Progile.TRIO.BaseModel.dll)

Inheritance Hierarchy:

Object Progile.TRIO.BaseModel.OnScreenElement Progile.TRIO.BaseModel.LabelWithElementBase Progile.TRIO.BaseModel.LabelWithButton

Constructors

Initializes a new instance of the LabelWithButton class.

LabelWithButton(ITester, string, RelativePosition, ImageReference, ImageReference, int, int, IImageFilter[ ])

Syntax:

public LabelWithButton(
	ITester tester,
	string displayName,
	RelativePosition buttonPosition,
	ImageReference imageReferenceForLabel,
	ImageReference imageReferenceForButton,
	int gridWidth = 0,
	int buttonLineHeight = 0,
	params IImageFilter[] filters
)

Parameters:

Parameter

Description

tester

The tester interface.

displayName

buttonPosition

imageReferenceForLabel

imageReferenceForButton

The image reference that will be used to locate the button on the screen.

[gridWidth]

The gridWith needs to be set for buttonPosition Left or Right

[buttonLineHeight]

The minimum Height of the line with the button.

The buttonLineHeight needs to be set for buttonPosition Above or Under

[filters]

The filters to find the label.

Exceptions:

Exception

Condition

ArgumentException

buttonLineHeight needs to be set if buttonPosition is Above or Under; gridWidth needs to be set if buttonPosition is Left or Right

LabelWithButton(ITester, string, RelativePosition, ImageReference, ImageReference, ImageReference, int, int, IImageFilter[ ])

Syntax:

public LabelWithButton(
	ITester tester,
	string displayName,
	RelativePosition buttonPosition,
	ImageReference imageReferenceForLabel,
	ImageReference buttonActiveimageReference,
	ImageReference buttonInactiveImageReference,
	int gridWidth = 0,
	int buttonLineHeight = 0,
	params IImageFilter[] filters
)

Parameters:

Parameter

Description

tester

The tester interface.

displayName

buttonPosition

imageReferenceForLabel

buttonActiveimageReference

The active image reference that will be used to locate the button on the screen.

buttonInactiveImageReference

The inactive image reference of the button. Will also be used to locate the button on the screen.

[gridWidth]

The gridWith needs to be set for buttonPosition Left or Right

[buttonLineHeight]

The minimum Height of the line with the button.

The buttonLineHeight needs to be set for buttonPosition Above or Under

[filters]

The filters to find the label.

Exceptions:

Exception

Condition

ArgumentException

buttonLineHeight needs to be set if buttonPosition is Above or Under; gridWidth needs to be set if buttonPosition is Left or Right

LabelWithButton(ITester, string, RelativePosition, string, string, int, int, IImageFilter[ ])

Syntax:

public LabelWithButton(
	ITester tester,
	string displayName,
	RelativePosition buttonPosition,
	string searchTextForLabel,
	string searchTextForButton,
	int gridWidth = 0,
	int buttonLineHeight = 0,
	params IImageFilter[] filters
)

Parameters:

Parameter

Description

tester

The tester interface.

displayName

buttonPosition

searchTextForLabel

searchTextForButton

The search text that will be used to locate the button on the screen.

[gridWidth]

The gridWith needs to be set for buttonPosition Left or Right

[buttonLineHeight]

The minimum Height of the line with the button.

The buttonLineHeight needs to be set for buttonPosition Above or Under

[filters]

The filters to find the label.

Exceptions:

Exception

Condition

ArgumentException

buttonLineHeight needs to be set if buttonPosition is Above or Under; gridWidth needs to be set if buttonPosition is Left or Right

Methods

Name

Description

Clicks on the button. Verifies the click was successful with the specified verification and performs retries if necessary.

Performs a double click on the button. Wait time between the individual clicks is controlled by the optional parameter doubleClickDelay.

Moves the mouse over the button. Verifies the hover was successful with the specified verification and performs retries if necessary.

Checks the state of the button. Returns true if the button is active, false if the button is inactive. Requires that images named "active" and "inactive" are present in the folder given as content.

Properties

Name

Description

Last updated

Was this helpful?