Code review comment for lp:~aacid/indicator-sound/absolute_icon_paths

Revision history for this message
Albert Astals Cid (aacid) wrote :

> gdk_pixbuf_new_from_file_at_scale will just return NULL if the file doesn't exist (or couldn't be read)
I thought that for that reason is better to fall back to the else case that will give me the default "not found" icon

> Also, the file might be deleted between the two calls.
True

> Why didn't you just use gtk_image_set_from_file?
Because it might not be of the size we want

> `pix` might be NULL, which is okay for gtk_image_set_from_pixbuf, but g_object_unref will print a warning. It
> would be preferable to print the actual error (pass the GError into gdk_pixbuf_new_from_file_at_scale).
Want me to create a new merge request for this?

« Back to merge proposal