daily pastebin goal
68%
SHARE
TWEET

Untitled

a guest Aug 13th, 2017 100 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
  2. #NoTrayIcon
  3. #SingleInstance force
  4. ; #Warn  ; Enable warnings to assist with detecting common errors.
  5. SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
  6. SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
  7.  
  8. ;Setup Browsers Group
  9. GroupAdd, Browsers, ahk_class Chrome_WidgetWin_1
  10. GroupAdd, Browsers, ahk_class ApplicationFrameWindow
  11.  
  12. ;Three Tap
  13. <#<^<+F22::
  14.     Sleep 1
  15.  
  16.     MouseGetPos, , , id
  17.     WinGetClass, class, ahk_id %id%
  18.     if ( class = "Shell_TrayWnd" ){         ; Send Middle-click if over Taskbar (for 7+ Taskbar Tweaker)
  19.         Send, {MButton}
  20.     }
  21.     else if WinActive("ahk_class CabinetWClass") {
  22.         Send, !{Up}
  23.     }
  24.     else if WinActive("ahk_exe foobar2000.exe") {
  25.         Send, {Media_Play_Pause}
  26.     }
  27.     else {
  28.         Send, {MButton}
  29.     }
  30. Return
  31.  
  32.  
  33. ;Three Swipe Up
  34. <^<!1::
  35.     Sleep 1
  36.     if ( WinActive("ahk_group Browsers") or WinActive("ahk_class CabinetWClass") ) {
  37.         Send, !{Right}          ;{Browser_Forward}
  38.     }
  39.     else if WinActive("ahk_exe foobar2000.exe") {
  40.         Send, {Media_Prev}
  41.     }
  42. Return
  43.  
  44.  
  45. ;Three Swipe Down
  46. <^<!2::
  47.     Sleep 1
  48.     if ( WinActive("ahk_group Browsers") or WinActive("ahk_class CabinetWClass") ) {
  49.         Send, !{Left}           ;{Browser_Back}
  50.     }
  51.     else if WinActive("ahk_exe foobar2000.exe") {
  52.         Send, {Media_Next}
  53.     }
  54. Return
  55.  
  56.  
  57. ;Three Swipe Left
  58. <^<!3::
  59.     Sleep 1
  60.     if ( WinActive("ahk_group Browsers") or WinActive("ahk_class TfrmMyLifeMain") or WinActive("ahk_exe foobar2000.exe") ) {
  61.         Send, ^+{Tab}
  62.     }
  63. Return
  64.  
  65.  
  66. ;Three Swipe Right
  67. <^<!5::
  68.     Sleep 1
  69.     if ( WinActive("ahk_group Browsers") or WinActive("ahk_class TfrmMyLifeMain") or WinActive("ahk_exe foobar2000.exe") ) {
  70.         Send, ^{Tab}
  71.     }
  72. Return
  73.  
  74.  
  75. ;Four Tap
  76. <#<^<+F24::
  77.     Sleep 1
  78.         ;if ( WinActive("ahk_group Browsers") or WinActive("ahk_exe foobar2000.exe") or WinActive("ahk_class CabinetWClass") ) {
  79.     Send, ^w
  80. Return
  81.  
  82. ;Four Swipe Up
  83. <^<!6::
  84.     Sleep 1
  85.     if WinActive("ahk_class WorkerW")
  86.     {
  87.         Send, #d
  88.         if WinActive("ahk_class WorkerW")
  89.         {
  90.             Send, #{Tab}
  91.         }
  92.     }
  93.     else if WinActive("ahk_class MultitaskingViewFrame")
  94.     {
  95.         Send, #^d
  96.     }
  97.     else
  98.     {
  99.         Send, #{Tab}
  100.     }
  101. Return
  102.  
  103. ;Four Swipe Down
  104. <^<!7::
  105.     Sleep 1
  106.     if WinActive("ahk_class WorkerW") {
  107.         Sleep 0
  108.     }
  109.     else if WinActive("ahk_class MultitaskingViewFrame") {
  110.         Send, #{Tab}
  111.     }
  112.     else {
  113.         Send, #d
  114.     }
  115. Return
RAW Paste Data
Top