diff options
author | Søren Sandmann <sandmann@redhat.com> | 2006-04-13 16:24:03 +0000 |
---|---|---|
committer | Søren Sandmann Pedersen <ssp@src.gnome.org> | 2006-04-13 16:24:03 +0000 |
commit | c7c9f0ee528ce876dd36cb13e747da6a2112034e (patch) | |
tree | f7ee6256e8bd6e6a528174da0b2e952453a1e141 /src/c-screen.c | |
parent | ea50cc7239c0f562ecf23d8f7a39e93f749c99bf (diff) | |
download | metacity-c7c9f0ee528ce876dd36cb13e747da6a2112034e.tar.gz |
Check for both POPUP and DROPDOWN.
Thu Apr 13 12:23:28 2006 Søren Sandmann <sandmann@redhat.com>
* src/c-screen.c (meta_screen_info_add_window): Check for both
POPUP and DROPDOWN.
Diffstat (limited to 'src/c-screen.c')
-rw-r--r-- | src/c-screen.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/c-screen.c b/src/c-screen.c index 29264181..e3bac07d 100644 --- a/src/c-screen.c +++ b/src/c-screen.c @@ -519,9 +519,9 @@ window_info_new (Window xwindow, } static gboolean -is_menu (WsWindow *window) +has_type (WsWindow *window, const char *check_type) { - gchar **types = ws_window_get_property_atom_list (window, "_NET_WM_UNMANAGED_WINDOW_TYPE"); + gchar **types = ws_window_get_property_atom_list (window, "_NET_WM_WINDOW_TYPE"); int i; gboolean result; @@ -534,7 +534,9 @@ is_menu (WsWindow *window) { gchar *type = types[i]; - if (strcmp (type, "_NET_WM_UNMANAGED_WINDOW_TYPE_DROPDOWN_MENU") == 0) + g_print ("type: %s\n", type); + + if (strcmp (type, check_type) == 0) { result = TRUE; break; @@ -613,13 +615,17 @@ out: g_print ("set alpha %f\n", alpha); #endif - if (is_menu (drawable)) + if (has_type (drawable, "_NET_WM_WINDOW_TYPE_DROPDOWN_MENU")) { #if 0 g_print ("is menu\n"); #endif alpha = 0.9; } + else if (has_type (drawable, "_NET_WM_WINDOW_TYPE_POPUP_MENU")) + { + alpha = 0.9; + } else { #if 0 |