Ctrl + n creates a new folder
Ctrl + b creates a new bookmark
Some dupe code, no effort made at refactoring.
Code: Select all
; -------------- Hotkeys for Firefox -----------------
#IfWinActive ahk_exe firefox.exe
; Shortcuts for Bookmarks window
^n:: ; New Folder
MouseGetPos,,,id,NN
ControlGetText, Text, %NN%, ahk_id %id%
if(Text != "Library") { ; The title of the bookmark window is 'Library'
Send ^n
return
}
; Tooltip Text=%Text%
Send !o
sleep 50
Send o
return
^b:: ; New Bookmark
MouseGetPos,,,id,NN
ControlGetText, Text, %NN%, ahk_id %id%
if(Text != "Library") { ; The title of the bookmark window is 'Library'
Send ^b
return
}
Send !o
sleep 50
Send b
return
#IfWinActive
; -------------- End hotkeys for Firefox -----------------