UpdatesPage: Don't try to translate version numbers
AbandonedPublic

Authored by jbbgameich on May 5 2019, 8:56 AM.

Details

Reviewers
None
Group Reviewers
Discover Software Store
Summary

Fixes a I18N_ARGUMENT_MISSING warning in the ui that appears sometimes while discover is looking for updates.

Test Plan

Version numbers are still displayed, and no warnings are visible

Diff Detail

Repository
R134 Discover Software Store
Branch
updates-page-i18n-versions (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 11565
Build 11583: arc lint + arc unit
jbbgameich created this revision.May 5 2019, 8:56 AM
Restricted Application added a project: Plasma. · View Herald TranscriptMay 5 2019, 8:56 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
jbbgameich requested review of this revision.May 5 2019, 8:56 AM
pino added a subscriber: pino.May 5 2019, 9:05 AM

The explanation of this change does not match the code changes: the code never translated the version numbers, but it composed a string showing the version numbers before and after the upgrade.
Could it simply be that one of the two (for example installedVersion) is null?

discover/qml/UpdatesPage.qml
239

I do not think this change is correct: "%1 → %2" is a UI string, and thus it must be translatable.

apol added a subscriber: apol.May 5 2019, 10:08 PM

Yep, change isn't correct. A solution would be to ad an installedVersion && availableVersion ? i18n(...) : "".

Or fix i18n() to not complain about "", although I'm pretty sure it's not easily doable.

ngraham added a subscriber: ngraham.May 6 2019, 3:31 PM
In D21029#461379, @apol wrote:

Yep, change isn't correct. A solution would be to ad an installedVersion && availableVersion ? i18n(...) : "".

+1

jbbgameich abandoned this revision.Jun 24 2019, 7:56 PM