testWidgetClick

This function will generate a button click (button press and button release event) in the middle of the first GdkWindow found that belongs to widget. For windowless widgets like #GtkButton (which returns false from gtk.widget.Widget.getHasWindow), this will often be an input-only event window. For other widgets, this is usually widget->window. Certain caveats should be considered when using this function, in particular because the mouse pointer is warped to the button click location, see gdk.global.testSimulateButton for details.

More...

Parameters

widget gtk.widget.Widget

Widget to generate a button click on.

button uint

Number of the pointer button for the event, usually 1, 2 or 3.

modifiers gdk.types.ModifierType

Keyboard modifiers the event is setup with.

Return Value

Type: bool

whether all actions neccessary for the button click simulation were carried out successfully.

Detailed Description

Deprecated: This testing infrastructure is phased out in favor of reftests.