Advertisement
08wckster08

Untitled

May 7th, 2020
2,324
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. WinSet, Transparent, 0
  2.  
  3. Gui, Add, GroupBox, x42 y39 w260 h170 , GroupBox
  4. Gui, Show, w479 h379, Untitled GUI
  5. FINF()
  6. return
  7.  
  8. GuiClose:
  9. FOUTF()
  10. ExitApp
  11.  
  12. FINF() {
  13.     WinGet, currentWindow, ID, A
  14.     fade("in",currentWindow)
  15. }
  16.  
  17. FOUTF() {
  18.     WinGet, currentWindow, ID, A
  19.     fade("out",currentWindow)
  20. }
  21.  
  22. fade(direction,ID) {
  23.     if (direction = "in")
  24.         transparency := 0
  25.     else
  26.         transparency := 255
  27.     loop
  28.     {
  29.         if (direction = "in")
  30.             transparency += 5
  31.         else
  32.             transparency -= 5
  33.         WinSet, Transparent, %transparency%, ahk_id %ID%
  34.         sleep 10
  35.         if ( transparency >= 255 ) or ( transparency <= 0 )
  36.             break
  37.     }
  38. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement