]> Dogcows Code - chaz/openbox/blobdiff - openbox/menuframe.c
add a window between the frame and the plate for drawing the client border. this...
[chaz/openbox] / openbox / menuframe.c
index f359c9852ee091b0c14e2793de5584fbc427b124..4cb2083dc1c7294b4d73114d322a136594beea22 100644 (file)
@@ -174,15 +174,15 @@ static void menu_entry_frame_free(ObMenuEntryFrame *self)
     if (self) {
         XDestroyWindow(ob_display, self->text);
         XDestroyWindow(ob_display, self->window);
-        g_hash_table_insert(menu_frame_map, &self->text, self);
-        g_hash_table_insert(menu_frame_map, &self->window, self);
+        g_hash_table_remove(menu_frame_map, &self->text);
+        g_hash_table_remove(menu_frame_map, &self->window);
         if (self->entry->type == OB_MENU_ENTRY_TYPE_NORMAL) {
             XDestroyWindow(ob_display, self->icon);
-            g_hash_table_insert(menu_frame_map, &self->icon, self);
+            g_hash_table_remove(menu_frame_map, &self->icon);
         }
         if (self->entry->type == OB_MENU_ENTRY_TYPE_SUBMENU) {
             XDestroyWindow(ob_display, self->bullet);
-            g_hash_table_insert(menu_frame_map, &self->bullet, self);
+            g_hash_table_remove(menu_frame_map, &self->bullet);
         }
 
         RrAppearanceFree(self->a_normal);
@@ -681,10 +681,10 @@ static gboolean menu_frame_show(ObMenuFrame *self)
 
     if (menu_frame_visible == NULL) {
         /* no menus shown yet */
-        if (!grab_pointer(TRUE, OB_CURSOR_POINTER))
+        if (!grab_pointer(TRUE, TRUE, OB_CURSOR_POINTER))
             return FALSE;
         if (!grab_keyboard(TRUE)) {
-            grab_pointer(FALSE, OB_CURSOR_POINTER);
+            grab_pointer(FALSE, TRUE, OB_CURSOR_POINTER);
             return FALSE;
         }
     }
@@ -809,7 +809,7 @@ void menu_frame_hide(ObMenuFrame *self)
 
     if (menu_frame_visible == NULL) {
         /* last menu shown */
-        grab_pointer(FALSE, OB_CURSOR_NONE);
+        grab_pointer(FALSE, TRUE, OB_CURSOR_NONE);
         grab_keyboard(FALSE);
     }
 
This page took 0.023666 seconds and 4 git commands to generate.