[Xfce4-commits] [xfce/xfce4-settings] 02/02: Ignore GdkScreen deprecations until upstream finds a solution

noreply at xfce.org noreply at xfce.org
Tue Jun 13 12:57:31 CEST 2017


This is an automated email from the git hooks/post-receive script.

b   l   u   e   s   a   b   r   e       p   u   s   h   e   d       a       c   o   m   m   i   t       t   o       b   r   a   n   c   h       m   a   s   t   e   r   
   in repository xfce/xfce4-settings.

commit d6d429afd992eb73c2773515d155d418f35afb5f
Author: Sean Davis <smd.seandavis at gmail.com>
Date:   Tue Jun 13 06:56:40 2017 -0400

    Ignore GdkScreen deprecations until upstream finds a solution
---
 dialogs/appearance-settings/main.c    | 4 +++-
 dialogs/display-settings/main.c       | 2 ++
 dialogs/display-settings/xfce-randr.c | 4 +++-
 xfsettingsd/displays.c                | 4 ++++
 4 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/dialogs/appearance-settings/main.c b/dialogs/appearance-settings/main.c
index f5b09c8..33c40e8 100644
--- a/dialogs/appearance-settings/main.c
+++ b/dialogs/appearance-settings/main.c
@@ -171,6 +171,7 @@ compute_xsettings_dpi (GtkWidget *widget)
     int width, height;
     int dpi;
 
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
     screen = gtk_widget_get_screen (widget);
     width_mm = gdk_screen_get_width_mm (screen);
     height_mm = gdk_screen_get_height_mm (screen);
@@ -183,6 +184,7 @@ compute_xsettings_dpi (GtkWidget *widget)
         dpi = MIN (INCH_MM * width  / width_mm,
                    INCH_MM * height / height_mm);
     }
+G_GNUC_END_IGNORE_DEPRECATIONS
 
     return dpi;
 }
@@ -1245,7 +1247,7 @@ appearance_settings_dialog_configure_widgets (GtkBuilder *builder)
     gtk_widget_set_sensitive (GTK_WIDGET (object2), gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (object)));
     g_signal_connect (G_OBJECT (object), "toggled", G_CALLBACK (cb_custom_dpi_check_button_toggled), object2);
     g_signal_connect (G_OBJECT (object2), "value-changed", G_CALLBACK (cb_custom_dpi_spin_button_changed), object);
-    
+
     /* Window scaling factor */
     object = gtk_builder_get_object (builder, "gdk_window_scaling_factor_combo_box");
     appearance_settings_dialog_channel_property_changed (xsettings_channel, "/Gdk/WindowScalingFactor", NULL, builder);
diff --git a/dialogs/display-settings/main.c b/dialogs/display-settings/main.c
index 336ad87..cf4d86c 100644
--- a/dialogs/display-settings/main.c
+++ b/dialogs/display-settings/main.c
@@ -820,8 +820,10 @@ display_setting_identity_display (gint display_id)
         {
             screen_pos_x = 0;
             screen_pos_y = 0;
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
             screen_width = gdk_screen_width ();
             screen_height = gdk_screen_height ();
+G_GNUC_END_IGNORE_DEPRECATIONS
         }
 
         name_label = g_markup_printf_escaped ("<span foreground='%s'><big><b>%s %s</b></big></span>",
diff --git a/dialogs/display-settings/xfce-randr.c b/dialogs/display-settings/xfce-randr.c
index 1453fdc..3f63afa 100644
--- a/dialogs/display-settings/xfce-randr.c
+++ b/dialogs/display-settings/xfce-randr.c
@@ -249,7 +249,7 @@ xfce_randr_populate (XfceRandr *randr,
 
         /* Update display info, primary display may have changed. */
         xfce_randr_save_output (randr, "Default", display_channel, m);
-        
+
         /* Replace spaces with underscore in name for xfconf compatibility */
         g_strcanon(randr->priv->output_info[m]->name, "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_<>", '_');
     }
@@ -626,6 +626,7 @@ xfce_randr_preferred_mode (XfceRandr *randr,
     best_dist = 0;
     for (n = 0; n < randr->priv->output_info[output]->nmode; ++n)
     {
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
         if (n < randr->priv->output_info[output]->npreferred)
             dist = 0;
         else if (randr->priv->output_info[output]->mm_height != 0)
@@ -634,6 +635,7 @@ xfce_randr_preferred_mode (XfceRandr *randr,
                     randr->priv->output_info[output]->mm_height);
         else
             dist = gdk_screen_height () - randr->priv->modes[output][n].height;
+G_GNUC_END_IGNORE_DEPRECATIONS
 
         dist = ABS (dist);
 
diff --git a/xfsettingsd/displays.c b/xfsettingsd/displays.c
index 97deac2..bf39f59 100644
--- a/xfsettingsd/displays.c
+++ b/xfsettingsd/displays.c
@@ -558,6 +558,7 @@ xfce_displays_helper_set_screen_size (XfceDisplaysHelper *helper)
         return;
     }
 
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
     xfsettings_dbg (XFSD_DEBUG_DISPLAYS, "min_h = %d, min_w = %d, max_h = %d, max_w = %d, "
                     "prev_h = %d, prev_w = %d, prev_hmm = %d, prev_wmm = %d, h = %d, w = %d, "
                     "hmm = %d, wmm = %d.", min_height, min_width, max_height, max_width,
@@ -578,6 +579,7 @@ xfce_displays_helper_set_screen_size (XfceDisplaysHelper *helper)
         XRRSetScreenSize (helper->xdisplay, GDK_WINDOW_XID (helper->root_window),
                           helper->width, helper->height, helper->mm_width, helper->mm_height);
     }
+G_GNUC_END_IGNORE_DEPRECATIONS
 }
 
 
@@ -857,6 +859,7 @@ xfce_displays_helper_list_outputs (XfceDisplaysHelper *helper)
                 if (helper->resources->modes[m].id != output->info->modes[l])
                     continue;
 
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
                 if (l < output->info->npreferred)
                     dist = 0;
                 else if (output->info->mm_height != 0)
@@ -864,6 +867,7 @@ xfce_displays_helper_list_outputs (XfceDisplaysHelper *helper)
                             1000 * helper->resources->modes[m].height / output->info->mm_height);
                 else
                     dist = gdk_screen_height () - helper->resources->modes[m].height;
+G_GNUC_END_IGNORE_DEPRECATIONS
 
                 dist = ABS (dist);
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list