Code: Select all
;############BROWSER BACK START##########
#If WinExist("- Google Chrome") and MouseIsOver("- Google Chrome") or WinExist("- Mozilla Firefox") and MouseIsOver("- Mozilla Firefox") or WinExist("Opera") and MouseIsOver("Opera")
MButton:: ; <-- Go Back, Browser Back
If MouseIsOver("Mozilla Firefox")
{
;Msgbox, 0, 0, Firefox Undo Closed Tab - Using XButton1 The Mouse is over Firefox, .4
Winactivate Mozilla Firefox
WinWaitActive Mozilla Firefox
Sleep 150
Send {BS}
Return
}
Else
;IfwinActive Opera
If MouseIsOver("- Opera")
{
;Msgbox, 0, 0, Opera Undo Closed Tab If Mouse is Over , 0.4
Winactivate Opera
WinWaitActive Opera
Sleep 150
Send {ALTDOWN}{Left}{ALTUP}
Return
}
Else
If MouseIsOver ("- Google Chrome")
{
;Msgbox, 0, 0, Opera Undo Closed Tab If Mouse is Over chrome, 1
; Winactivate ahk_class Chrome_WidgetWin_1
; WinWaitActive ahk_class Chrome_WidgetWin_1
WinActivate Google Chrome
WinWaitActive Google Chrome
Sleep 250
Send !{Left}
Return
}
Else
Return
#If
#IfWinExist
#If Winexist
#iftimeout