summaryrefslogtreecommitdiff
path: root/eel
diff options
context:
space:
mode:
Diffstat (limited to 'eel')
-rw-r--r--eel/eel-background.c8
-rw-r--r--eel/eel-gtk-extensions.c5
2 files changed, 9 insertions, 4 deletions
diff --git a/eel/eel-background.c b/eel/eel-background.c
index 76f47a69..b096650a 100644
--- a/eel/eel-background.c
+++ b/eel/eel-background.c
@@ -311,9 +311,13 @@ drawable_get_adjusted_size (EelBackground *self,
{
if (self->details->is_desktop)
{
+ gint sc_width, sc_height;
GdkScreen *screen = gtk_widget_get_screen (self->details->widget);
- *width = gdk_screen_get_width (screen);
- *height = gdk_screen_get_height (screen);
+
+ gdk_window_get_geometry (gdk_screen_get_root_window (screen), NULL, NULL,
+ &sc_width, &sc_height);
+ *width = sc_width;
+ *height = sc_height;
}
else
{
diff --git a/eel/eel-gtk-extensions.c b/eel/eel-gtk-extensions.c
index 800fe6cd..b9d870c5 100644
--- a/eel/eel-gtk-extensions.c
+++ b/eel/eel-gtk-extensions.c
@@ -168,8 +168,9 @@ eel_gtk_window_set_initial_geometry (GtkWindow *window,
real_top = top;
screen = gtk_window_get_screen (window);
- screen_width = gdk_screen_get_width (screen);
- screen_height = gdk_screen_get_height (screen);
+
+ gdk_window_get_geometry (gdk_screen_get_root_window (screen), NULL, NULL,
+ &screen_width, &screen_height);
/* This is sub-optimal. GDK doesn't allow us to set win_gravity
* to South/East types, which should be done if using negative