messageTray: Use a GIcon for a notification's icon/secondary icon

Using a GIcon instead of an actor means that we can always create
a new icon with the right size from an old icon.

https://bugzilla.gnome.org/show_bug.cgi?id=680426
This commit is contained in:
Jasper St. Pierre
2012-09-14 11:33:52 -03:00
parent b7acb1d488
commit 928ea3bb01
4 changed files with 39 additions and 35 deletions

View File

@ -1747,10 +1747,9 @@ const NMApplet = new Lang.Class({
or this._source will be cleared */
this._ensureSource();
let icon = new St.Icon({ icon_name: iconName,
icon_size: MessageTray.NOTIFICATION_ICON_SIZE });
let gicon = new Gio.ThemedIcon({ name: iconName });
device._notification = new MessageTray.Notification(this._source, title, text,
{ icon: icon });
{ gicon: gicon });
device._notification.setUrgency(urgency);
device._notification.setTransient(true);
device._notification.connect('destroy', function() {