power: indicate 1 hour remaining correctly
Before 60 minutes remaining were displayed as "0 minutes" now it is "1 hour". https://bugzilla.gnome.org/show_bug.cgi?id=687958
This commit is contained in:
parent
6f2da1baf1
commit
e757b06987
@ -96,7 +96,7 @@ const Indicator = new Lang.Class({
|
|||||||
let minutes = time % 60;
|
let minutes = time % 60;
|
||||||
let hours = Math.floor(time / 60);
|
let hours = Math.floor(time / 60);
|
||||||
let timestring;
|
let timestring;
|
||||||
if (time > 60) {
|
if (time >= 60) {
|
||||||
if (minutes == 0) {
|
if (minutes == 0) {
|
||||||
timestring = ngettext("%d hour remaining", "%d hours remaining", hours).format(hours);
|
timestring = ngettext("%d hour remaining", "%d hours remaining", hours).format(hours);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user