Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #cs
- Local $toggle = False
- Local $origHWnd
- HotKeySet("^`", "HideWin")
- Func HideWin()
- If $toggle = False Then
- $origHWnd = WinGetHandle("[ACTIVE]")
- WinSetState("[ACTIVE]", "", @SW_HIDE)
- $toggle = True
- Else
- WinSetState($origHWnd, "", @SW_SHOW)
- WinActivate($origHWnd)
- $toggle = False
- EndIf
- EndFunc
- While True
- GUIGetMsg()
- WEnd
- #CE
- #include <Array.au3>
- Local $toggleWin[3] = [False, False, False]
- Local $origHWnd[3]
- HotKeySet("^!1", "HideWin1")
- HotKeySet("^!2", "HideWin2")
- HotKeySet("^!3", "HideWin3")
- Func HideWin1()
- DoHideWin(0)
- EndFunc
- Func HideWin2()
- DoHideWin(1)
- EndFunc
- Func HideWin3()
- DoHideWin(2)
- EndFunc
- Func DoHideWin($winNumber)
- If $toggleWin[$winNumber] = False Then
- $origHWnd[$winNumber] = WinGetHandle("[ACTIVE]")
- WinSetState("[ACTIVE]", "", @SW_HIDE)
- $toggleWin[$winNumber] = True
- Else
- WinSetState($origHWnd[$winNumber], "", @SW_SHOW)
- WinActivate($origHWnd[$winNumber])
- $toggleWin[$winNumber] = False
- EndIf
- EndFunc
- While True
- GUIGetMsg()
- WEnd
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement