Option to open tab in foreground upon Ctrl+Shift+Up

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
skyd
Junior Member
Junior Member
Posts: 10
Joined: 2010-03-15, 23:16 UTC

Option to open tab in foreground upon Ctrl+Shift+Up

Post by *skyd »

"Configuration -> Folder Tabs" contain "Ctrl+Up opens new tab in foreground".

Is it possible to add a "Ctrl+Shift+Up opens new tab in foreground" checkbox?
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

Ctrl+Shift+Up already used for opening folder in new tab on target panel.

But you may assign another command for Ctrl+Shift+Up shortcut - open Configuration - Misc and assign for Ctrl+Shift+Up command cm_OpenDirInNewTab - so TC will open new tab in foreground on Ctrl+Shift+Up.
skyd
Junior Member
Junior Member
Posts: 10
Joined: 2010-03-15, 23:16 UTC

Post by *skyd »

Sorry, I wasn't clear enough..

I'd like Ctrl+Shift+Up to behave hexactly like it does today.
The problem is that if I press the key combination, a new tab will open in the target panel, but the target panel won't become active.

The addition is that I would like the target panel to also become active.

I guess the checkbox's text should be:
"Ctrl+Shift+Up opens new tab on target panel in foreground".
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

I understood you. BTW, "Ctrl+Shift+Up opens new tab on target panel in foreground" also sounds not correctly. I think, better name is "Ctrl+Shift+Up opens new tab on target panel and activate it".

You may assign to Ctrl+Shift+Up some em_command that will send to TC commands cm_OpenDirInNewTabOther and cm_TrgActivateTab10 together using tool like TCMC (i.e. TC will open dir in new tab of target panel and activate that panel). Just be sure you have no tab with specified number (cm_TrgActivateTab10 will activate 10th tab of target panel or just put focus to active target tab if target panel hav no 10th tab). So better is to send command #5199 instead of #5109 (i.e. cm_TrgActivateTab99). Using TCMC command may be like this:

Code: Select all

<path_to_TCMC.exe> CM3004 CM5199
(also you may specify optional delay in ms as first parameter)

Just create em_command using cm_CommandBrowser and assign shortcut Ctrl+Shift+Up using Configuration - Misc.
skyd
Junior Member
Junior Member
Posts: 10
Joined: 2010-03-15, 23:16 UTC

Post by *skyd »

Took me a while to decipher all you've written (I never wrote a custom command before), but now that I have it up and running I have to say I'm impressed with your answer - it really hit the spot.

One thing I'm disappointed at is the need to run an external tool instead of TC having a built-in multiple-commands option for an em_command.. How about adding THAT as an RFE?
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

A glance---

Post by *Clo »

2skyd

:) Hello !
…(I never wrote a custom command before)…
• Maybe a glance HERE could help ? ;)

:mrgreen: KR
Claude
Clo[face=arial][/face]
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
skyd
Junior Member
Junior Member
Posts: 10
Joined: 2010-03-15, 23:16 UTC

Post by *skyd »

It wasn't easy for me to find how to write a cm_command because this forum's search engine is too basic, so I googled for it and the page you refer to is the exact one I used in order to understand how to do the cm_command thingy.

Thanks anyway! :)
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

skyd wrote:One thing I'm disappointed at is the need to run an external tool instead of TC having a built-in multiple-commands option for an em_command.. How about adding THAT as an RFE?
Such little tool may help in many cases. It is better to have it than to have no wanted function :)
skyd wrote:I googled for it and the page you refer to is the exact one I used in order to understand how to do the cm_command thingy.
I'll correct you a bit. cm_commands are internal TC commands. You may create only em_commands (in usercmd.ini or in wcmd_xxx.ini). Defining em_command looks like defining new buttonbar button but such commands may be used with assigned hotkeys.
skyd
Junior Member
Junior Member
Posts: 10
Joined: 2010-03-15, 23:16 UTC

Post by *skyd »

Yes, em_commands.
I wasn't aware of all this so I'm just getting used to the new terminology.

Thanks a lot for your help! - You opened a whole new world for me :)
skyd
Junior Member
Junior Member
Posts: 10
Joined: 2010-03-15, 23:16 UTC

Not working as expected in TC9

Post by *skyd »

@MVV: I know that time has passed, but this is a really natural feature to me already. Sadly, in TC9 this doesn't work as expected anymore.

Looks like the operation now runs in an async manner because instead of activating the newly opened tab, the one before it gets activated (the one that was last on the list before opening the current folder in the target window).

Another behavior change is that if the tab being activated is not visible - it will remain invisible (it used to come into view in earlier versions).

Can anything be done about this?
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

I've just tried this command from a button, and it seems that CM5199 command only activates target panel but doesn't switch to last tab when there is no 99th tab... But I've checked TC 9.0a, 8.52a, 8.01a, 7.56a - and it is so in all of them...

Partially it works fine with enabled "Ctrl+Up opens new tab in foreground" option on Folder Tabs configuration page though.
skyd
Junior Member
Junior Member
Posts: 10
Joined: 2010-03-15, 23:16 UTC

Post by *skyd »

I have TC9.0 running on a fresh PC and I didn't grab the old config file, rather started configuring from scratch. That's why I thought it's a TC9.0 issue..
MVV wrote:Partially it works fine with enabled "Ctrl+Up opens new tab in foreground"
It doesn't partially work, it fully works! That was the missing piece.

Once again - You tha man!
Thank you very much!
Post Reply