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

EditorFileDialog: disambiguate recent/favorite items #63552

Merged
merged 1 commit into from
Aug 30, 2022

Conversation

RedMser
Copy link
Contributor

@RedMser RedMser commented Jul 27, 2022

Implements part of godotengine/godot-proposals#2876

Similar to the script editor, if two folders have the same name in any editor file dialog (e.g. Open Scene), they will now get a more descriptive name in the item list. Note that this is not showing the full path, it just adds the parent folder name where needed.

Also made the formatting more consistent by removing the trailing slash for both lists.

image

Copy link
Member

@akien-mga akien-mga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me overall. Maybe some others in @godotengine/gui-nodes or @godotengine/_editor want to check it too.

@akien-mga
Copy link
Member

Might also need a rebase just in case as we've been changing core APIs a lot recently.

@reduz
Copy link
Member

reduz commented Aug 30, 2022

Indeed, without the trailing slash should be perfect.

@RedMser
Copy link
Contributor Author

RedMser commented Aug 30, 2022

I did following changes:

  • Rebase onto master
  • Fix the logic responsible for filtering out non-res:// paths
  • Remove trailing /

@RedMser
Copy link
Contributor Author

RedMser commented Aug 30, 2022

Just found a bug when access == ACCESS_FILESYSTEM which clears all favorites/recentdirs, must fix this first.

Similar to script editor, if two folders have the same name, they will
now get a more descriptive name in the item list.
@RedMser
Copy link
Contributor Author

RedMser commented Aug 30, 2022

OK I tested everything again (both kinds of file browsers - res:// path and OS path) and they show and keep recentdirs/favorites correctly.

@RedMser RedMser requested a review from akien-mga August 30, 2022 15:44
@akien-mga akien-mga merged commit de5f13e into godotengine:master Aug 30, 2022
@akien-mga
Copy link
Member

Thanks!

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

Successfully merging this pull request may close these issues.

4 participants