[gtk+/wip/otte/gtk4: 4/41] inspector: Port to GdkMonitor
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/otte/gtk4: 4/41] inspector: Port to GdkMonitor
- Date: Thu, 6 Oct 2016 22:00:04 +0000 (UTC)
commit b04ddaab1c7d86be95393053b095062f6a79a467
Author: Benjamin Otte <otte redhat com>
Date: Sun Sep 4 21:51:41 2016 +0200
inspector: Port to GdkMonitor
gtk/inspector/visual.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/gtk/inspector/visual.c b/gtk/inspector/visual.c
index b3da229..bb36432 100644
--- a/gtk/inspector/visual.c
+++ b/gtk/inspector/visual.c
@@ -571,14 +571,14 @@ static void
init_scale (GtkInspectorVisual *vis)
{
#if defined (GDK_WINDOWING_X11)
- GdkScreen *screen;
+ GdkDisplay *display;
- screen = gdk_screen_get_default ();
- if (GDK_IS_X11_SCREEN (screen))
+ display = gdk_display_get_default ();
+ if (GDK_IS_X11_DISPLAY (display))
{
gdouble scale;
- scale = gdk_screen_get_monitor_scale_factor (screen, 0);
+ scale = gdk_monitor_get_scale_factor (gdk_display_get_primary_monitor (display));
gtk_adjustment_set_value (vis->priv->scale_adjustment, scale);
g_signal_connect (vis->priv->scale_adjustment, "value-changed",
G_CALLBACK (scale_changed), vis);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]