Merge lp:~unity-team/unity/group-icons into lp:unity

Proposed by Mikkel Kamstrup Erlandsen on 2010-09-09
Status: Merged
Merged at revision: 490
Proposed branch: lp:~unity-team/unity/group-icons
Merge into: lp:unity
Diff against target: 19 lines (+6/-1)
1 file modified
unity-private/places/places-default-renderer-group.vala (+6/-1)
To merge this branch: bzr merge lp:~unity-team/unity/group-icons
Reviewer Review Type Date Requested Status
Mirco Müller (community) 2010-09-09 Needs Information on 2010-09-09
Review via email: mp+34957@code.launchpad.net

Description of the change

Loads icons for group headers in places if the model sets the appropriate icon hint

To post a comment you must log in.
Mirco Müller (macslow) wrote :

Code itself looks ok. But I don't know in which cases the icon (or fallback image) are meant to show up. Using trunk versions of the place-daemons for files and applications, I don't get any icon in the headers. Is that expected behaviour?

review: Needs Information

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'unity-private/places/places-default-renderer-group.vala'
2--- unity-private/places/places-default-renderer-group.vala 2010-09-02 23:52:53 +0000
3+++ unity-private/places/places-default-renderer-group.vala 2010-09-09 09:59:45 +0000
4@@ -131,9 +131,14 @@
5 title_box.show ();
6
7 icon = new Ctk.Image (22);
8- icon.set_from_filename (Config.PKGDATADIR + "/favourites.png");
9 title_box.pack (icon, false, false);
10 icon.show ();
11+ if (icon_hint != null && icon_hint != "")
12+ PixbufCache.get_default().set_image_from_gicon_string (icon,
13+ icon_hint,
14+ 22);
15+ else
16+ icon.set_from_filename (Config.PKGDATADIR + "/favourites.png");
17
18 text = new Ctk.Text (display_name);
19 text.set_markup ("<big>" + Markup.escape_text (display_name) + "</big>");