sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #05064
[Bug 695720] Re: X-1.0rc2: "with Region:" and "Region.click()" with App().window() --- workaround
** Changed in: sikuli
Status: New => Fix Committed
--
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/695720
Title:
X-1.0rc2: "with Region:" and "Region.click()" with App().window() ---
workaround
Status in Sikuli:
Fix Committed
Bug description:
**** workaround ****
type cast to Region:
r = Region(App("application").window())
--------------------------------------------------------------------
# I use Sikuli X on windows XP.
# The Grouping Method Calls (with Region:) works when using Region()
def Region_with():
reg = Region(468,212, 344, 570)
reg.highlight(2)
with reg:
sleep(1)
# But fails when using App().window()
def window_with():
reg= App("SOMEAPP").window(0)
reg.highlight(2)
with reg:
sleep(1)
# Error Message: AttributeError: 'org.sikuli.script.Region' object has
no attribute '__exit__'
# Simalar problem happend on reg.click(), works for Region()
def Region_click():
reg = Region(468,212, 344, 570)
reg.highlight(2)
reg.click(image1)
# But fails on App().window()
def window_click():
reg= App("SOMEAPP").window(0)
reg.highlight(2)
reg.click( image1)
# Error Message: TypeError: click(): expected 2 args; got 1
To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/695720/+subscriptions
References