Skip to content

Conversation

@gkatev
Copy link
Contributor

@gkatev gkatev commented Oct 6, 2025

Hi,

In the list view, you can expand folders to view their content without actually navigating into them, potentially multiple levels deep at once. The Open Terminal in the active folder button on the toolbar does not work well in such situations, as it always opens the terminal in the top/root folder, even if a folder deep down in the expanded hierarchy is selected.

This PR proposes/implements a change in this behaviour, making the terminal toolbar button work the same way as the Create a new folder button, which does take into account the currently selected folder in the hierarchy.

  • If no folder is selected, opens terminal in the top-most folder.
  • If a non-expanded folder or a file is selected, opens terminal in its parent's directory.
  • If an expanded folder is selected, opens terminal in the selected folder.

I was inspired to use nemo_view_get_backing_uri() from nemo_view_new_folder(). Tested on 6.4.5.

@mtwebster
Copy link
Member

I think the toolbar button is behaving correctly here. It opens a terminal in the active location. All toolbar buttons are this way - they don't behave differently depending on the selected file or folder within the view.

You use the context menu to act on the selection (such as opening a terminal there).

@mtwebster mtwebster closed this Nov 17, 2025
@gkatev
Copy link
Contributor Author

gkatev commented Nov 17, 2025

All toolbar buttons are this way - they don't behave differently depending on the selected file or folder within the view.

This is not accurate. The New folder toolbar button does work in the way I'm advocating for. If you have selected a folder which is expanded, and you press the new folder button, the new folder is created under the selected folder.

It opens a terminal in the active location.

I would argue that when you have a List view, and you have folders expanded, the active (in a non-techincal terms) location is not necessarily the top-level one, but the one which you are fiddling in. Imagine if wou will, that you are working e.g. 2, 3, 4 levels deep in an expanded hierarchy -- in a sense this is your current working directory.

@mtwebster mtwebster reopened this Nov 24, 2025
@mtwebster
Copy link
Member

mtwebster commented Nov 24, 2025

I don't agree with the behavior of new-folder this way, but who am I to stand in the way of precedent.

@mtwebster mtwebster merged commit 8d5b48e into linuxmint:master Nov 24, 2025
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

Successfully merging this pull request may close these issues.

2 participants