summaryrefslogtreecommitdiff
path: root/src/ui/tabpopup.c
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2017-12-04 09:31:43 +0100
committerraveit65 <[email protected]>2017-12-20 20:40:01 +0100
commitd094cf0297f28b826ca742379750567750dfee9f (patch)
treeb360036c8649bdfc054ed1e7c0cb96be436b38b2 /src/ui/tabpopup.c
parent202a8006e2b551ca909c7aa1b67720d699771df3 (diff)
downloadmarco-d094cf0297f28b826ca742379750567750dfee9f.tar.bz2
marco-d094cf0297f28b826ca742379750567750dfee9f.tar.xz
WidthOfScreen and HeightOfScreen implementation
This commit reverts: https://github.com/mate-desktop/marco/commit/f0541e3dfda29c26fe14c9c9117f95c49006c75c https://github.com/mate-desktop/marco/commit/d18c2fb4acb58c408c01700682b9922de86e8b2f And it applies an alternative to fix the deprecated functions: gdk_screen_get_width gdk_screen_width gdk_screen_height
Diffstat (limited to 'src/ui/tabpopup.c')
-rw-r--r--src/ui/tabpopup.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/ui/tabpopup.c b/src/ui/tabpopup.c
index f3d64733..f3d14240 100644
--- a/src/ui/tabpopup.c
+++ b/src/ui/tabpopup.c
@@ -34,6 +34,7 @@
#include "../core/frame-private.h"
#include "draw-workspace.h"
#include <gtk/gtk.h>
+#include <gdk/gdkx.h>
#include <math.h>
#define OUTSIDE_SELECT_RECT 2
@@ -259,9 +260,7 @@ meta_ui_tab_popup_new (const MetaTabEntry *entries,
popup->current_selected_entry = NULL;
popup->border = border;
- gdk_window_get_geometry (gdk_screen_get_root_window (screen), NULL, NULL,
- &screen_width, NULL);
-
+ screen_width = WidthOfScreen (gdk_x11_screen_get_xscreen (screen));
for (i = 0; i < entry_count; ++i)
{
TabEntry* new_entry = tab_entry_new (&entries[i], screen_width,