-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Code Quality: Update localization to use centralized Strings class 09 #16957
Merged
yaira2
merged 8 commits into
files-community:main
from
mrashutoshnigam:codeQuality/replaceStringsLiteralsWithContants_16718_09
Mar 19, 2025
Merged
Code Quality: Update localization to use centralized Strings class 09 #16957
yaira2
merged 8 commits into
files-community:main
from
mrashutoshnigam:codeQuality/replaceStringsLiteralsWithContants_16718_09
Mar 19, 2025
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Refactor localization strings in archive compression and decompression actions to utilize a new `Strings` class. This change replaces direct string literals with references to the centralized resource management, enhancing maintainability and consistency across the application. Affected classes include `CompressIntoArchiveAction`, `CompressIntoSevenZipAction`, `CompressIntoZipAction`, `DecompressArchive`, `DecompressArchiveHere`, `DecompressArchiveHereSmart`, and `DecompressArchiveToChildFolderAction`. The `ComputeLabel` method in `DecompressArchiveToChildFolderAction` has also been updated for consistent localization.
Refactor `Label` and `Description` properties in `PlayAllAction`, `RefreshItemsAction`, `ShareItemAction`, and `OpenAllTaggedActions` to use a centralized `Strings` class for improved maintainability and consistency in localization across the application.
Refactor the `Label` and `Description` properties in `GitFetchAction`, `GitInitAction`, `GitPullAction`, `GitPushAction`, and `GitSyncAction` to utilize a new `Strings` resource. This change improves the maintainability and consistency of localization across the application.
Updated `PinFolderToSidebarAction.cs` and `UnpinFolderToSidebarAction.cs` to retrieve localized strings using a `Strings` class instead of string literals. This change enhances maintainability and organization of localization resources.
Refactor localization strings in `PinToStartAction.cs` and `UnpinFromStartAction.cs` to use a centralized `Strings` class. This change replaces hardcoded string keys for the `Label` and `Description` properties, improving maintainability and consistency across the application.
I've already done this in #16944 |
yaira2
approved these changes
Mar 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Code Quality: Update Localization for Git and Sidebar Action Classes
This pull request enhances the maintainability and consistency of localization handling across the application by refactoring string management in Git, Sidebar, and Pin/Unpin actions to use a centralized
Strings
class.Closes #16718
Changes Made
Refactored Git Action Classes: Updated the
Label
andDescription
properties in the following Git-related action classes to use theStrings
resource:GitFetchAction
GitInitAction
GitPullAction
GitPushAction
GitSyncAction
Refactored Sidebar Action Classes: Updated localization in the following sidebar-related action classes to retrieve localized strings from the
Strings
class:PinFolderToSidebarAction
UnpinFolderToSidebarAction
Refactored Pin/Unpin Actions: Updated localization strings for pinning and unpinning actions to use the centralized
Strings
class:PinToStartAction
UnpinFromStartAction
Benefits
Testing Steps
Additional Notes
Strings
class.