aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/Makefile.am2
-rw-r--r--lib/main.vala7
2 files changed, 7 insertions, 2 deletions
diff --git a/lib/Makefile.am b/lib/Makefile.am
index a8486211..1d88add2 100644
--- a/lib/Makefile.am
+++ b/lib/Makefile.am
@@ -1,4 +1,4 @@
-AM_CFLAGS = -DGNOME_DESKTOP_USE_UNSTABLE_API
+AM_CFLAGS = -w -DGNOME_DESKTOP_USE_UNSTABLE_API
AM_LDFLAGS = -lm
AM_VALAFLAGS = --enable-experimental-non-null \
--metadatadir $(top_srcdir)/deps \
diff --git a/lib/main.vala b/lib/main.vala
index 2081414e..30d186cc 100644
--- a/lib/main.vala
+++ b/lib/main.vala
@@ -591,7 +591,12 @@ public class Indicator.Keyboard.Service : Object {
var menu_item = new MenuItem (name, "indicator.current");
menu_item.set_attribute (Menu.ATTRIBUTE_TARGET, "u", i);
- menu_item.set_icon ((!) get_icon (i));
+
+ var icon = get_icon (i);
+ if (icon != null) {
+ menu_item.set_icon ((!) icon);
+ }
+
menu.append_item (menu_item);
}
} else {