[1.1.4] Windows: app focus and close only work if app instance has an associated window
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SikuliX |
In Progress
|
Medium
|
RaiMan |
Bug Description
-------
someApp.focus() and someApp.close() will only work, if the app object created with App("some.
-------
In complex cases like portable Chrome, there is no associated window with the main process and hence it is only possible to focus the app with a part of the window title, which in turn allows to get the app object with the window-owning process, that in turn is focusable and closeable.
-------
1.1.4-SNAPSHOT-
Windows 10 64bit
I used this script to open two portable chrome instances and then tried to change the focus to them or close them with .focus() and .close() method but nothing happens:
open_instances = {} # a dictionary to keep record of opened browsers {name:app}
def browser(target, action = True ):
temp = r"C:\Users\
if action: #for opening
else: # for closing
del open_instances[
wait(1)
def main():
for i in range(1,3): # trying to open the instances which works fine
browser(i)
wait(2)
for i in range(1,3): # trying to close same instances but it does not work. I even tried the .focus() but no success either
browser(i, False)
main()
summary: |
- app focus and close does not work + [1.1.4] Windows: app focus and close does not work anymore (since 1st + Jan '19) |
Changed in sikuli: | |
status: | New → Fix Committed |
importance: | Undecided → High |
assignee: | nobody → RaiMan (raimund-hocke) |
milestone: | none → 1.1.4 |
description: | updated |
Changed in sikuli: | |
status: | In Progress → Confirmed |
importance: | Medium → Undecided |
description: | updated |
summary: |
- [1.1.4] Windows: app focus and close should work for more than one - instance running of same some-name.exe + [1.1.4] Windows: app focus and close only work if app instance has an + associated window |
Changed in sikuli: | |
status: | Confirmed → In Progress |
importance: | Undecided → Medium |
milestone: | 1.1.4 → 2.1.0 |
Tested with the latest build (> #180):
everything works as expected.