Merge lp://qastaging/~dgadomski/ubuntu-rssreader-app/relative-time-formatting into lp://qastaging/~ubuntu-shorts-dev/ubuntu-rssreader-app/trunk
Status: | Merged |
---|---|
Approved by: | Joey Chan |
Approved revision: | 22 |
Merged at revision: | 25 |
Proposed branch: | lp://qastaging/~dgadomski/ubuntu-rssreader-app/relative-time-formatting |
Merge into: | lp://qastaging/~ubuntu-shorts-dev/ubuntu-rssreader-app/trunk |
Diff against target: |
520 lines (+116/-74) 10 files modified
ArticleFullImg.qml (+4/-3) ArticleOneImgA.qml (+4/-3) ArticleOneImgB.qml (+4/-3) ArticleTextA.qml (+4/-3) ArticleTextB.qml (+4/-3) ArticleTwoImgA.qml (+4/-3) ListColumnDelegate.qml (+2/-2) ListColumnView.qml (+1/-1) addDelegate.js (+19/-19) dateutils.js (+70/-34) |
To merge this branch: | bzr merge lp://qastaging/~dgadomski/ubuntu-rssreader-app/relative-time-formatting |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Ubuntu Phone Apps Jenkins Bot | continuous-integration | Approve | |
Ubuntu Shorts Developers | Pending | ||
Joey Chan | Pending | ||
David Planella | Pending | ||
Review via email: mp+176435@code.qastaging.launchpad.net |
Commit message
Improved relative time formatting utility.
Description of the change
This is my second approach to provide a more generic and flexible relative time formatting utility. This one incorporates an array of formatters which may be adjusted when needed.
There are 2 new formats added 'borrowed' from the calculator app: displaying that something happened yesterday ("Yesterday at %1") or within a week from now (by using the weekday name).
I have tested this version and it works just fine with gettext (all strings are extracted correctly for translations).
Unfortunately, since i18n is a QML context property (confirmed in Ubuntu UI toolkit source code: http://
I believe in this form it can be easily reused in ubuntu-
Looks like all is ok, w8 while guys will review your code too :)