PhieuLang

Click

Aug 29th, 2013
125
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
AutoIt 0.76 KB | None | 0 0
  1. #include <Array.au3>
  2. Global $Paused
  3.  
  4.  
  5. if Not HotKeySet("{F6}", "click12") then Exit
  6. if Not HotKeySet("{F7}","copy") then Exit
  7. if Not HotKeySet("{F8}", "TogglePause") then Exit
  8.  
  9.  
  10. Func copy()
  11.    if Not WinExists("[Class:Chrome_WidgetWin_1]","") Then Return 1
  12.    $list = WinList("[Class:Chrome_WidgetWin_1]","")
  13.    if StringInStr($list[1][0],'.html') Then
  14.       ClipPut(StringReplace($list[1][0],'.html - Google Chrome',''))
  15.    Else
  16.       $title = WinGetTitle("")
  17.      ClipPut(StringReplace($title,'.html - Google Chrome',''))
  18.   EndIf
  19. EndFunc
  20.  
  21. Func click12()
  22.    Local $pos = MouseGetPos()
  23.    While 1  
  24.       MouseClick("",$pos[0],$pos[1])
  25.    WEnd
  26. EndFunc
  27.  
  28. Func TogglePause()
  29.    $Paused = Not $Paused
  30.    While $Paused
  31.         Sleep(100)
  32.    WEnd
  33. EndFunc
Advertisement
Add Comment
Please, Sign In to add comment