Skip to content
Snippets Groups Projects
Commit 6880fba3 authored by Philipp Hörist's avatar Philipp Hörist
Browse files

Raise exception for missing icons

This is a regression from gajim/gajim@9dc389cc

previously we used load_icon() which raises an exception for missing icons

now we use lookup_icon() which does not, and iconinfo can be None now
parent 6d9f82d8
No related branches found
No related tags found
No related merge requests found
......@@ -59,6 +59,8 @@ class Color:
def get_icon_pixmap(icon_name, size=16, color=None, quiet=False):
try:
iconinfo = gtk_icon_theme.lookup_icon(icon_name, size, 0)
if not iconinfo:
raise GLib.GError
if color:
pixbuf, was_symbolic = iconinfo.load_symbolic(*color)
return pixbuf
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment