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

Allow renaming to change the case of Windows directories #43068

Merged
merged 1 commit into from
Oct 2, 2021

Conversation

cooperra
Copy link
Contributor

Somewhat related to #42992, but different and on Windows.

Here are the steps to reproduce the problem that this fixes:

  • On Windows, create a new folder "Foo" in Godot's file panel
  • Right-click -> Rename
  • Enter "foO" in the rename dialog that appears and submit it
  • Expected: the folder is renamed to "foO".
  • Actual: Error moving: Foo alert and the name is unchanged

This was only a problem with folders. Files already had a fix.

I should point out that the ::_wrename() call used to rename the folders also works on files, so it doesn't seem like the "juggling" workaround in the existing fix is needed anymore, at least on my system.

Tested on Windows 10.

@cooperra cooperra requested a review from hpvb as a code owner October 25, 2020 07:47
@Calinou Calinou added bug platform:windows topic:core cherrypick:3.x Considered for cherry-picking into a future 3.x release labels Oct 25, 2020
@Calinou Calinou added this to the 4.0 milestone Oct 25, 2020
Copy link
Contributor

@theraot theraot left a comment

Choose a reason for hiding this comment

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

This change fixes the bug. Tested on Windows 10.

I tried testing on Windows 7, but could not because I could not get Vulkan able drivers. Godot 4 will not run in Vista or XP due to unrelated causes.

I also tried cherry-picking it. The code needs to be changed to use c_str() instead of utf16().get_data() to work in the 3.x branch. With that change the 3.x build worked in Windows 7. So I'm confident this change would have worked for me in Windows 7 if it weren't because Vulkan.

@akien-mga akien-mga merged commit d97f223 into godotengine:master Oct 2, 2021
@akien-mga
Copy link
Member

Thanks for the fix, and for the testing and review! Looks good to me too.

@akien-mga
Copy link
Member

Cherry-picked for 3.4.

@akien-mga akien-mga removed the cherrypick:3.x Considered for cherry-picking into a future 3.x release label Oct 4, 2021
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