After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 635288 - Update for gnome-power-manager API changes
Update for gnome-power-manager API changes
Status: RESOLVED FIXED
Product: gnome-shell
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2010-11-19 18:00 UTC by Giovanni Campagna
Modified: 2010-11-22 17:06 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
PowerStatus: Update for gnome-power-manager API changes (3.57 KB, patch)
2010-11-19 18:00 UTC, Giovanni Campagna
needs-work Details | Review
PowerStatus: Update for gnome-power-manager API changes (3.28 KB, patch)
2010-11-19 21:34 UTC, Giovanni Campagna
committed Details | Review
Complete porting to new gnome-power-manager API (2.47 KB, patch)
2010-11-20 17:21 UTC, Giovanni Campagna
committed Details | Review

Description Giovanni Campagna 2010-11-19 18:00:20 UTC
Following bug 633703, g-p-m DBus API has changed, and the shell is now broken. We need to fix it.
Comment 1 Giovanni Campagna 2010-11-19 18:00:44 UTC
Created attachment 174867 [details] [review]
PowerStatus: Update for gnome-power-manager API changes

g-p-m no longer exports a summary, and instead exports a GIcon to
show. Update for that.
Comment 2 Dan Winship 2010-11-19 18:40:50 UTC
Comment on attachment 174867 [details] [review]
PowerStatus: Update for gnome-power-manager API changes

>+        this._label = new St.Label({ text: GPMGettext.gettext(this._deviceTypeToString(device_type)) });

Hm. No, don't use g-p-m's translations for strings that are coming from our source code; if g-p-m tweaks things again later (eg, maybe changing capitalization of something), then we'd suddenly lose translations. So just use _() and we'll make our own translations.

>+            return 'AC Adapter';

'AC adapter', for consistency with the other strings

>+            return 'Chell phone';

typo
Comment 3 Giovanni Campagna 2010-11-19 21:34:06 UTC
Created attachment 174889 [details] [review]
PowerStatus: Update for gnome-power-manager API changes

g-p-m no longer exports a summary, and instead exports a GIcon to
show. Update for that.
Comment 4 Giovanni Campagna 2010-11-20 17:21:19 UTC
Not fixed yet, see below...
Comment 5 Giovanni Campagna 2010-11-20 17:21:46 UTC
Created attachment 174915 [details] [review]
Complete porting to new gnome-power-manager API

We updated the normal devices part, but we forgot the part about
the primary device (possibly because it is not reported as such
in case it is fully charged). Update that as well, to avoid showing
weird GIcon serializations.