I have some simple ahk code that works great when I am using Firefox, but I cannot construct an equivalent for Chrome. The idea is that the functional part of the code should only "apply" when Chrome is open and the active (focused) window.
Here is what works for Firefox:
;MUST BE LAST PART OF SCRIPT!!
SetTitleMatchMode, 2
`#IfWinActive, - Mozilla Firefox
;Above "- Mozilla Firefox" substring appears in all Firefox windows
{code to be applicable goes here}
`#ifwinactive
The problem is that Chrome has no Window Title, so I cannot construct the `#IfWinActive line.
Does anyone have an idea how this can be done for Chrome? And perhaps even so that the script could detect EITHER Firefox OR Chrome being active and focused?