Skip to content

Commit 678664f

Browse files
committed
Make WinWaitNotActive return a boolean
1 parent e673868 commit 678664f

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

ahkpy/Lib/Commands.ahk

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -614,10 +614,5 @@ _WinWaitClose(WinTitle="",WinText="",Seconds="",ExcludeTitle="",ExcludeText="")
614614

615615
_WinWaitNotActive(WinTitle="",WinText="",Seconds="",ExcludeTitle="",ExcludeText="") {
616616
WinWaitNotActive %WinTitle%,%WinText%,%Seconds%,%ExcludeTitle%,%ExcludeText%
617-
if (ErrorLevel > 0) {
618-
return 0
619-
}
620-
; Get Last Found Window
621-
WinGet, id, ID
622-
return id
617+
return not ErrorLevel
623618
}

0 commit comments

Comments
 (0)