Add Lock action.
[mikachu/openbox.git] / openbox / client_menu.c
index c6cdd63..f34c8ef 100644 (file)
@@ -121,6 +121,9 @@ static void client_menu_execute(ObMenuEntry *e, ObMenuFrame *f,
     if (!c)
         return;
 
+    if (c->locked)
+        return;
+
     if (!config_focus_under_mouse)
         ignore_start = event_start_ignore_all_enters();
 
@@ -218,6 +221,9 @@ static void layer_menu_execute(ObMenuEntry *e, ObMenuFrame *f,
 
     g_assert(c);
 
+    if (c->locked)
+        return;
+
     if (!config_focus_under_mouse)
         ignore_start = event_start_ignore_all_enters();
 
@@ -290,6 +296,9 @@ static void send_to_menu_execute(ObMenuEntry *e, ObMenuFrame *f,
 {
     g_assert(c);
 
+    if (c->locked)
+        return;
+
     client_set_desktop(c, e->id, FALSE, FALSE);
     if (f && c->desktop != screen_desktop && c->desktop != DESKTOP_ALL)
         /* the client won't even be on the screen anymore, so hide the menu */