AutoHotkey: Locate in TC: Difference between revisions
Jump to navigation
Jump to search
m (Comment about localization added) |
m (Some readability improvements) |
||
Line 13: | Line 13: | ||
sFileName := "" | sFileName := "" | ||
sPath := "" | sPath := "" | ||
ControlGet | ControlGet sActiveRow, LIST, SELECTED, SysListView321 | ||
StringSplit aRowElements, sActiveRow, %A_Tab% | StringSplit aRowElements, sActiveRow, %A_Tab% | ||
sFileName := aRowElements1 | sFileName := aRowElements1 | ||
Line 20: | Line 20: | ||
if (sFileName != "") | if (sFileName != "") | ||
{ | { | ||
Run | Run "%COMMANDER_PATH%\Totalcmd.exe" /O /T "%sPath%" | ||
WinWaitActive | WinWaitActive ahk_class TTOTAL_CMD | ||
PostMessage | PostMessage 1075, 2915 ;call quicksearch box | ||
WinWaitActive ahk_class TQUICKSEARCH | WinWaitActive ahk_class TQUICKSEARCH | ||
ControlSetText TTabEdit1, %sFileName% | ControlSetText TTabEdit1, %sFileName% |
Revision as of 14:39, 2 February 2006
Pressing Ctrl-F in Locate finds the selected file in TC. Original credits go to gbo and icfu
;Ctrl-F (Locate: finds selected file in TC) $^f:: ;This works only with the english localization of Locate If not WinActive( "Locate", "Presets" ) { Send ^f Return } sFileName := "" sPath := "" ControlGet sActiveRow, LIST, SELECTED, SysListView321 StringSplit aRowElements, sActiveRow, %A_Tab% sFileName := aRowElements1 sPath := aRowElements2 if (sFileName != "") { Run "%COMMANDER_PATH%\Totalcmd.exe" /O /T "%sPath%" WinWaitActive ahk_class TTOTAL_CMD PostMessage 1075, 2915 ;call quicksearch box WinWaitActive ahk_class TQUICKSEARCH ControlSetText TTabEdit1, %sFileName% ControlSend TTabEdit1, {Down}{Esc} } Return
Back to AutoHotkey