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

Add Localization to the Power Source #340

Merged
merged 1 commit into from Feb 8, 2021
Merged

Add Localization to the Power Source #340

merged 1 commit into from Feb 8, 2021

Conversation

Tai-Zhou
Copy link
Contributor

@Tai-Zhou Tai-Zhou commented Feb 8, 2021

Add two terms to all the languages and add localizations of widgets to Bulgarian and Romanian.

Before localization: before

After localization: after

Add two terms to all the languages and add localizations of widgets to Bulgarian and Romanian.
@exelban
Copy link
Owner

exelban commented Feb 8, 2021

Hi. Thanks.

@exelban exelban merged commit 1761d9c into exelban:master Feb 8, 2021
@@ -224,7 +224,7 @@ internal class Popup: NSView, Popup_p {
self.dashboardBatteryView?.setValue(abs(value.level))

self.levelField?.stringValue = "\(Int(abs(value.level) * 100)) %"
self.sourceField?.stringValue = value.powerSource
self.sourceField?.stringValue = "\(LocalizedString(value.powerSource))"
Copy link
Owner

Choose a reason for hiding this comment

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

I noticed it after merge. LocalizedString returns a String. So you don't need to pass it throw quotes. It could be simplified with this: self.sourceField?.stringValue = LocalizedString(value.powerSource).

But it's ok)

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.

None yet

2 participants