Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Opening Files via the keyboard shortcut always opens a new tab #2301

Open
TomiOhl opened this issue Aug 29, 2023 · 6 comments
Open

Opening Files via the keyboard shortcut always opens a new tab #2301

TomiOhl opened this issue Aug 29, 2023 · 6 comments

Comments

@TomiOhl
Copy link
Contributor

TomiOhl commented Aug 29, 2023

What Happened?

When I open Files via a keyboard shortcut (Super+E for me, not sure if that's the default or I've changed it), it always opens my home folder on a new tab, even if it's opened on an other tab.
Related: if Files is already open and I use the keyboard shortcut, it doesn't only bring it into focus, but also opens a new tab.

Steps to Reproduce

  1. Open Files via a keyboard shortcut
  2. Close Files
  3. Open it again via a keyboard shortcut

Expected Behavior

The keyboard shortcut should simply open the application (or bring it into focus if it's already open). It shouldn't open a new tab, especially if there is already one (or more).

OS Version

7.x (Horus)

Software Version

Latest release (I have run all updates)

Log Output

No response

Hardware Info

No response

@lenemter
Copy link
Member

This looks like a duplicate of elementary/switchboard-plug-keyboard#74.

You need to add a custom shortcut io.elementary.files and assign shortcut. After that it should work as expected.

@TomiOhl
Copy link
Contributor Author

TomiOhl commented Aug 29, 2023

Partially maybe but not entirely. It definitely didn't work like this before the latest update.
Previously it didn't open another new tab if one was already open. Right now if I use the shortcut I always end up with at least two home folder tabs.

@jeremypw
Copy link
Collaborator

May be related to #2272. Not sure which, if any, option is used when opening Files from the system system shortcut. However, you do not get the extra tab if opening from the commandline which is odd. Will investigate. A similar issue is being fixed in Terminal

@jeremypw
Copy link
Collaborator

You only get an extra tab from the commandline if you actually give a URI with the -t option which is what I would expect.

@jeremypw
Copy link
Collaborator

jeremypw commented Aug 29, 2023

If you create a custom shortcut for opening Files with the command io.elementary.files then there is no extra tab. I think the issue is related to the fact that the shortcut is for opening Files at the Home Folder which probaby uses the command io.elementary.files -t ~ (need to check). This forces the creation of a new tab at the Home Folder.

@jeremypw
Copy link
Collaborator

We need to do like Terminal and have a command that does not create a duplicate tab if the requested (Home) folder is already restored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants