[gnote] Fix empty items in application menu



commit 168e0af364dde946602b19dbdc5c7b73a6d13309
Author: Aurimas Černius <aurisc4 gmail com>
Date:   Sun Jan 5 18:52:11 2014 +0200

    Fix empty items in application menu
    
    Happens on desktop environments that don't have application menu and
    thus window has menu. Empty items are caused by section name labels that
    are empty strings rather than NULLs.

 src/actionmanager.cpp |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/actionmanager.cpp b/src/actionmanager.cpp
index c1e9df0..c7f460e 100644
--- a/src/actionmanager.cpp
+++ b/src/actionmanager.cpp
@@ -1,7 +1,7 @@
 /*
  * gnote
  *
- * Copyright (C) 2011-2013 Aurimas Cernius
+ * Copyright (C) 2011-2014 Aurimas Cernius
  * Copyright (C) 2009 Hubert Figuiere
  *
  * This program is free software: you can redistribute it and/or modify
@@ -178,17 +178,17 @@ namespace gnote {
     int pos = 0;
     Glib::RefPtr<Gio::Menu> section = make_app_menu_section(APP_ACTION_NEW);
     if(section != 0) {
-      menu->insert_section(pos++, "", section);
+      menu->insert_section(pos++, section);
     }
 
     section = make_app_menu_section(APP_ACTION_MANAGE);
     if(section != 0) {
-      menu->insert_section(pos++, "", section);
+      menu->insert_section(pos++, section);
     }
 
     section = make_app_menu_section(APP_ACTION_LAST);
     if(section != 0) {
-      menu->insert_section(pos++, "", section);
+      menu->insert_section(pos++, section);
     }
 
     return menu;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]