AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Drag & Drop

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
wolive



Joined: 20 Jul 2004
Posts: 21
Location: South Africa

PostPosted: Sat Mar 26, 2005 6:50 am    Post subject: Drag & Drop Reply with quote

I would like to create a hotkey that enables and disables drag and drop on the desktop. I share my PC with my kids and they generally re-position my icons on the desktop. Any idea how I can detect if the mouse has moved while the left mouse button is down.
Back to top
View user's profile Send private message
Jon



Joined: 28 Apr 2004
Posts: 373

PostPosted: Sat Mar 26, 2005 9:09 pm    Post subject: Reply with quote

This script will not let you click on a desktop icon for more than 200ms-

Code:
~*Lbutton::

MouseGetPos, , , , OutputVarControl

;if the desktoop  is under the mouse
if OutputVarControl = SysListView321
{

;if mouse is held for 200ms
sleep, 200

;automatically release left mouse button
MouseClick, Left, , , , , U
}

return
Back to top
View user's profile Send private message Send e-mail
Laszlo



Joined: 14 Feb 2005
Posts: 4078
Location: Pittsburgh

PostPosted: Sun Mar 27, 2005 12:23 am    Post subject: Reply with quote

Clever!
Back to top
View user's profile Send private message
wolive



Joined: 20 Jul 2004
Posts: 21
Location: South Africa

PostPosted: Sun Mar 27, 2005 7:21 am    Post subject: Reply with quote

Thanks. It's exactly what I was looking for.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group