Last active
October 27, 2020 17:20
-
-
Save veirus/5eb960aa38dfa1285403ddd194a5944a to your computer and use it in GitHub Desktop.
quickly share a picture from browser to somewhere else
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#v:: | |
; CoordMode, Mouse, Screen | |
SetKeyDelay, 200 | |
;--------------------------- | |
#IfWinNotActive, ahk_class MozillaWindowClass | |
WinActivate, MozillaWindowClass | |
; Send, {Click, right, 470, 674}{y} | |
Send, {Click, right, 960, 600} | |
#IfWinActive, ahk_class MozillaDropShadowWindowClass | |
{ | |
clipboard := "" ; Empty the clipboard | |
Send, {y} | |
ClipWait, 3, 1 | |
if ErrorLevel | |
{ | |
MsgBox, The attempt to copy picture onto the clipboard failed. | |
return | |
} | |
; MsgBox, clipboard = %clipboard% | |
; return | |
} | |
Send, {Esc} | |
Send, x | |
;--------------------------- | |
WinActivate, Telegram | |
Sleep, 500 | |
Send, ^v | |
Sleep, 800 | |
Send, {Enter} | |
Sleep, 250 | |
;--------------------------- | |
WinActivate, ahk_class MozillaWindowClass | |
return |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment