superreview requested: [Bug 410215] GTK's .xpm decoding is weird, stop using XPM as the default window icon : [Attachment 295160] Patch v. 1 for review

Justin Dolske <dolske@mozilla.com> has asked Robert O'Callahan (:roc)
<roc@ocallahan.org> for superreview:
Bug 410215: GTK's .xpm decoding is weird, stop using XPM as the default window
icon
https://bugzilla.mozilla.org/show_bug.cgi?id=410215

Attachment 295160: Patch v.1 for review
https://bugzilla.mozilla.org/attachment.cgi?id=295160&action=edit

------- Additional Comments from Justin Dolske <dolske@mozilla.com>
This changes the icon setting code to prefer a PNG, and if no PNG is found it
falls back to looking for an XPM. This allow us to start switching apps over to
PNG without forcing everyone to change at once.

I went ahead and rolled in support for additional icon sizes, which would be
needed by bug 404402. I only added the sizes recommended by:

http://library.gnome.org/devel/gtk/2.8/GtkWindow.html#gtk-window-set-icon-list

There's overhead for each size queried -- looks like we stat() in each
extension's directory, each time a window is opened. So, we probably don't want
this list to include every conceivable icon size.

SetDefaultIcon() seemed to be needlessly duplicating code, so I just have it
use SetIcon() now too.

Tested on Solaris, confirmed the XPM fallback works and that when multiple
icons are count GTK seems to prefer the right size.
0
bugzilla
1/3/2008 12:27:14 AM
mozilla.dev.super-review 29307 articles. 3 followers. Post Follow

0 Replies
388 Views

Similar Articles

[PageSpeed] 0

Reply: