summaryrefslogtreecommitdiff
path: root/src/display.c
diff options
context:
space:
mode:
authorHavoc Pennington <hp@pobox.com>2002-09-04 04:15:46 +0000
committerHavoc Pennington <hp@src.gnome.org>2002-09-04 04:15:46 +0000
commitcbb0b8e66cd094b19f005d3559679f5dbfcaafd9 (patch)
tree85fc4715645d276cccf8c3056278f69ffec33bb9 /src/display.c
parenta6a7407faa0fa30cb62cfc0494c2d905d975412b (diff)
downloadmetacity-cbb0b8e66cd094b19f005d3559679f5dbfcaafd9.tar.gz
metacity-cbb0b8e66cd094b19f005d3559679f5dbfcaafd9.tar.bz2
new function
2002-09-03 Havoc Pennington <hp@pobox.com> * src/display.c (meta_display_get_tab_current): new function * src/keybindings.c (do_choose_window): apply modified patch from JeyaSudha to still display tab popup if only one window is on the desktop.
Diffstat (limited to 'src/display.c')
-rw-r--r--src/display.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/display.c b/src/display.c
index f5d7a5d..d622be3 100644
--- a/src/display.c
+++ b/src/display.c
@@ -3119,6 +3119,26 @@ meta_display_get_tab_next (MetaDisplay *display,
display->mru_list);
}
+MetaWindow*
+meta_display_get_tab_current (MetaDisplay *display,
+ MetaTabList type,
+ MetaScreen *screen,
+ MetaWorkspace *workspace)
+{
+ MetaWindow *window;
+
+ window = display->focus_window;
+
+ if (window != NULL &&
+ window->screen == screen &&
+ IN_TAB_CHAIN (window, type) &&
+ (workspace == NULL ||
+ meta_window_visible_on_workspace (window, workspace)))
+ return window;
+ else
+ return NULL;
+}
+
int
meta_resize_gravity_from_grab_op (MetaGrabOp op)
{