LDTP  2.3.1
hasstate

Syntax

hasstate('<window name>', '<object name>', <object SPI state>[, <guitimeout>])

Description

Checks the SPI state of the given object.

Return values
1on success, 0 on failure

Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py

Example

With respect to gedit window, first tab

from ldtp import *

hasstate('*-gedit', 'txt0', state.FOCUSABLE)

Wait for FOCUSABLE state till 10 seconds to be enabled

hasstate('*-gedit', 'txt0', state.FOCUSABLE, 10)

Author
Nagappan Alagappan nagap.nosp@m.pan@.nosp@m.gmail.nosp@m..com


Linux Desktop Testing Project