AutoHotkey Community

It is currently May 27th, 2012, 1:07 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: May 2nd, 2008, 6:29 am 
Offline

Joined: December 6th, 2007, 12:48 pm
Posts: 364
Hi,
I use xplorer² to manage my files, for those who don't know it's is a dual-pane layout filemanager to replace explorer.
The sad thing about this program is that so far I haven't found a native keyboard hotkey so switch between the panels. To do that, I must move my mouse to the destination pane area then click to activate it.
That's why I thought about this easy workaround:

Code:
SetTitleMatchMode, 2

=::
IfWinActive, xplorer²
{
   mousemove, 909, 520,
   
}

else
{
   send =
}
return

-::
IfWinActive, xplorer²
{
   mousemove, 498, 520,
   
}
else
{
   send -
}
return


As you can see, the purpose is: if the xplorer² Window is active, pressing "=" would move the mouse to the area that certainly belongs to the right pane, while pressing "-" would move the mouse to the left. However, the code like it is has a problem; it displays the following message as soon as I execute the script:
Quote:
71 hotkeys were received in the last 1049ms. Would you like to continue?"

... and the normal = and - are unavailable even when the xplorer² window is not active.
How to fix that?
:)

_________________
AHK is perfect.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 2nd, 2008, 6:55 am 
Offline

Joined: February 8th, 2008, 9:17 pm
Posts: 31
Location: VA
#IfWinActive is easier and you dont need the last commas in the MouseMove
also I would look into using the ahk_class as given by the window spy utility rather than title match but thats just my personal preference. title match also works
Code:
SetTitleMatchMode, 2

#IfWinActive xplorer²

=::mousemove, 909, 520 ;,

-::mousemove, 498, 520 ;,

#IfWinActive


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 2nd, 2008, 5:45 pm 
Offline

Joined: December 6th, 2007, 12:48 pm
Posts: 364
Oh my God
I feel so retarded for not knowing how to handle these simple powerful commands...
Thanks a lot, bro.

I just found a vert lil problem: the "-" character is bad for this function, since, as a filemanager, I often have to rename files with -'s. So I decided to change the key to move the cursor to the left to " ' ", next to the "1", in the same key as the quotation mark. My keyboard is Brazilian abnt2, (yours probably has the ~ instead). It doesn't work :(

However I could assign the ' key to another thing:

Code:
; Win+'
#'::WinMinimizeAll


Since this last uses # as the modifier, I think it wouldn't be a problem.

_________________
AHK is perfect.


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Amandaville, BrandonHotkey, chaosad and 22 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group