aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPavel Labath <pavelo@centrum.sk>2011-07-03 12:49:20 (GMT)
committerPavel Labath <pavelo@centrum.sk>2011-11-01 09:57:21 (GMT)
commit99cd3491e20d65f100e9693f879b9ef9e6d10687 (patch)
tree8e885c7f5c26ef99db1b38235f669343096f695a
parent8399b4cadf39156614175f56c4f5d568651da6c7 (diff)
downloadfluxbox_paul-99cd3491e20d65f100e9693f879b9ef9e6d10687.zip
fluxbox_paul-99cd3491e20d65f100e9693f879b9ef9e6d10687.tar.bz2
Report unrecognized menu entries
I put the error message into the menu, because noone reads stderr anyway.
-rw-r--r--src/MenuCreator.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/MenuCreator.cc b/src/MenuCreator.cc
index 467f643..ea45487 100644
--- a/src/MenuCreator.cc
+++ b/src/MenuCreator.cc
@@ -268,9 +268,12 @@ insertMenuItem(lua::state &l, FbTk::Menu &menu, FbTk::StringConvertor &parent_co
268 reloader, program) ); 268 reloader, program) );
269 } else if (str_key == "workspaces") { 269 } else if (str_key == "workspaces") {
270 menu.insert(str_label, RefMenu(screen->workspaceMenu()) ); 270 menu.insert(str_label, RefMenu(screen->workspaceMenu()) );
271 } else { 271 // finally, try window-related commands
272 // finally, try window-related commands 272 } else if(! MenuCreator::createWindowMenuItem(str_key, str_label, menu)) {
273 MenuCreator::createWindowMenuItem(str_key, str_label, menu); 273 // everything failed, we give up
274 int size = menu.insert(_FB_XTEXT(Menu, UnknownType, "Unknown menu type: ",
275 "The text will be followed by the actual type") + str_key);
276 menu.setItemEnabled(size-1, false);
274 } 277 }
275 } 278 }
276 279