← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #272494]: Popup or Input box On Top

 

Question #272494 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/272494

RaiMan proposed the following answer:
ok, this is a workaround (tested with OS X 10.11):

# a function that runs an applescript, that brings SikuliX to front
def sikulixToFront():
    cmd = '''
    applescript
    tell application "System Events"
        set xapp to first item of (processes whose displayed name is "SikuliX")
    end tell
    set frontmost of xapp to true
    '''
    runScript(cmd)

# test: Safari to front
switchApp("Safari")
wait(2)

#instead of App.focus("SikuliX")
sikulixToFront()
popup("continue?")

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.