Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Global LinkPath := "[File path to linkclick.cur]"
- Global MovePath := "[File path to moveclick.cur]"
- #NoEnv
- SetBatchLines, -1
- ~LButton::
- ~RButton::
- ~MButton::
- CurrentCursor := GetCursorHandle()
- if (CurrentCursor = 32649) {
- h := DllCall("LoadCursorFromFile", "Str", LinkPath)
- DllCall("SetSystemCursor", "Ptr", h, "Int", 32649)
- }
- else if (CurrentCursor = 32646) {
- h := DllCall("LoadCursorFromFile", "Str", MovePath)
- DllCall("SetSystemCursor", "Ptr", h, "Int", 32646)
- }
- return
- ~LButton Up::
- ~RButton Up::
- ~MButton Up::
- DllCall("SystemParametersInfo", "UInt", 0x57, "UInt", 0, "Ptr", 0, "UInt", 0)
- return
- GetCursorHandle() {
- VarSetCapacity(ci, 16 + A_PtrSize, 0)
- NumPut(16 + A_PtrSize, ci)
- DllCall("GetCursorInfo", "Ptr", &ci)
- hCursor := NumGet(ci, 8)
- if (hCursor = DllCall("LoadCursor", "Ptr", 0, "Int", 32649))
- return 32649
- if (hCursor = DllCall("LoadCursor", "Ptr", 0, "Int", 32646))
- return 32646
- return 0
- }
Advertisement
Add Comment
Please, Sign In to add comment