Shift+Click on Path column to open new tab

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
arazi89
Posts: 26
Joined: 08 Jul 2023 16:03

Shift+Click on Path column to open new tab

Post by arazi89 »

Currently when I double-click on a path in the Path column that is displayed with the results of a Quick Search it opens that path in the same tab-- overwriting the Quick Search results.

If I hold shift and Shift+Double Click then it opens that directory in a new tab, preserving the tab with the Quick Search results. Is there any way to reverse this-- and have the default Double-Click action to be to open the path in a new tab? Overwriting the Quick Search results tab is not ideal since it takes time to reload it.

In scripting it is: tab("new", "<curitempath>"); But I don't know how to assign that to the Path column in Quick Search.

Thank you!
XYplorer 27.10.0800 LLP
Windows 11 Home 24H2 26100.6584

admin
Site Admin
Posts: 64847
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Shift+Click on Path column to open new tab

Post by admin »

What's wrong with Shift+Double Click?

arazi89
Posts: 26
Joined: 08 Jul 2023 16:03

Re: Shift+Click on Path column to open new tab

Post by arazi89 »

admin wrote: 10 Aug 2023 08:25 What's wrong with Shift+Double Click?
Nothing is "wrong" with it. That is what I am doing now.

But just as nothing is wrong with Shift+Double Click nothing is wrong with Alt+Shift+Double Click or Ctrl+Alt+Shift+Double Click or any other number of multiple key presses using both hands that are not as fast and convenient as simply double-clicking with the mouse. It's not the end of the world, but with an awesome program with 5,000 different options this is just one more potential option that I would use every day.

I do a Quick Search of: tab("new", "<get list_recentlyopenedfiles>?/silent=1"); with customized columns that is one of the default tabs that I use all of time as a hub to launch programs and other tabs. I use it constantly. And that is why the difference between one-handed double-click versus two-handed Shift+Double Click is noticeable after using it so much.

Thanks!
XYplorer 27.10.0800 LLP
Windows 11 Home 24H2 26100.6584

highend
Posts: 14566
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Shift+Click on Path column to open new tab

Post by highend »

Easily solvable...

Menu - Tools - Configuration...
Find and Filter
Find Files & Branch View
[ ] Search results inherit current columns

Now do your quicksearch
While that view is open, add a new custom column and place it e.g. to the right of the path column

Code: Select all

Caption: E.g. "Open"
Type: Script
Script: tab("new", <cc_path>);
Format: Text
Trigger: Click
Item type: Files and Folders
When done, save your settings.

Now whenever you do a new quicksearch you can just click the "play" button in that custom column to open the path.

A single left click, no modifiers necessary...
Quick search.png
Quick search.png (349.66 KiB) Viewed 1053 times
One of my scripts helped you out? Please donate via Paypal

arazi89
Posts: 26
Joined: 08 Jul 2023 16:03

Re: Shift+Click on Path column to open new tab

Post by arazi89 »

highend wrote: 10 Aug 2023 16:30 Easily solvable...

Menu - Tools - Configuration...
Find and Filter
Find Files & Branch View
[ ] Search results inherit current columns
....

Now whenever you do a new quicksearch you can just click the "play" button in that custom column to open the path.

A single left click, no modifiers necessary...
Yes, yes, yes!

I had not yet learned to use the "Click" Trigger to stash all kinds of scripting code in a custom column and only run if/when clicked on the 'Play' button. As in this example. I implemented this and it works perfectly. As an added bonus the custom column with the 'Play' button can be widened and then positioning the mouse anywhere in that custom column -- not just directly over the 'Play' icon -- can trigger it. So, I was able to make that column fairly wide giving an ample sized target for the mouse.

You have no idea how many times I will be clicking on those little 'Play' buttons in this particular use.

Thank You!!!
XYplorer 27.10.0800 LLP
Windows 11 Home 24H2 26100.6584

sasumner
Posts: 26
Joined: 12 Mar 2015 12:21

Re: Shift+Click on Path column to open new tab

Post by sasumner »

Nice solution, highend ; bonus points for a mod to it that auto-selects the item (from the Quick Search's Name column) when the new tab opens?

highend
Posts: 14566
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Shift+Click on Path column to open new tab

Post by highend »

Not really difficult...

Code: Select all

    if (<cc_isfolder>) {
        tab("new", <cc_item>);
    } else {
        $file = <cc_name>;
        tab("new", <cc_path>);
        selectitems $file;
    }
One of my scripts helped you out? Please donate via Paypal

sasumner
Posts: 26
Joined: 12 Mar 2015 12:21

Re: Shift+Click on Path column to open new tab

Post by sasumner »

Nice work to select the item; but if the containing folder has a large number of items, and the item-to-select is not near the top, the selected item isn't shown to me (unless I manually scroll down looking for it).

My solution was to add this line after the selectitems $file; line:

Code: Select all

        sel "+0"; focus;  // scroll selected item into user's view

admin
Site Admin
Posts: 64847
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Shift+Click on Path column to open new tab

Post by admin »

The next version makes it a little easier:

Code: Select all

    * SC tab("new"): Now you can pass a file path in the data argument, and the new tab 
      will open at the containing folder and the file will be focused and selected.

highend
Posts: 14566
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Shift+Click on Path column to open new tab

Post by highend »

It would be cool if "newb" would support that as well!
One of my scripts helped you out? Please donate via Paypal

admin
Site Admin
Posts: 64847
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Shift+Click on Path column to open new tab

Post by admin »

OK, but there is a little caveat:

Code: Select all

      Works as well for tab("newb") but on selecting the tab the selected item is not 
      automatically moved into view.
Forget it, I made it work. :)

highend
Posts: 14566
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Shift+Click on Path column to open new tab

Post by highend »

:tup:
One of my scripts helped you out? Please donate via Paypal

highend
Posts: 14566
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Shift+Click on Path column to open new tab

Post by highend »

I'm using this with the new beta:

Code: Select all

    $where = "newb";
    if (<get trigger callshift> == 1) { $where = "new"; }
    tab($where, <cc_item>);
I like to open tabs as background ones (don't need to leave the open search for this) and only with shift directly...
One of my scripts helped you out? Please donate via Paypal

Post Reply