[Xfce4-commits] <xfce4-settings:master> Improve debug statements
Nick Schermer
noreply at xfce.org
Sun Oct 28 10:45:15 CET 2012
Updating branch refs/heads/master
to 22b558bf644ecfd0fdf81ea91e8fe71c36980131 (commit)
from 46eb5cbcb513aac30fa009fd50fca36de1a922fc (commit)
commit 22b558bf644ecfd0fdf81ea91e8fe71c36980131
Author: Lionel Le Folgoc <lionel at lefolgoc.net>
Date: Thu Oct 18 15:23:59 2012 +0200
Improve debug statements
Signed-off-by: Simon Steinbeiss <simon.steinbeiss at elfenbeinturm.at>
xfsettingsd/displays.c | 16 ++++++++++------
1 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/xfsettingsd/displays.c b/xfsettingsd/displays.c
index 5af8614..2212092 100644
--- a/xfsettingsd/displays.c
+++ b/xfsettingsd/displays.c
@@ -412,6 +412,10 @@ xfce_displays_helper_set_outputs (XfceRRCrtc *crtc,
g_assert (crtc);
+ for (n = 0; n < crtc->noutput; ++n)
+ xfsettings_dbg (XFSD_DEBUG_DISPLAYS, "CRTC %lu, output list[%d] -> %lu.", crtc->id, n,
+ crtc->outputs[n]);
+
/* check if the output is already present */
for (n = 0; n < crtc->noutput; ++n)
{
@@ -430,9 +434,8 @@ xfce_displays_helper_set_outputs (XfceRRCrtc *crtc,
crtc->outputs [crtc->noutput++] = output;
crtc->changed = TRUE;
- for (n = 0; n < crtc->noutput; ++n)
- xfsettings_dbg (XFSD_DEBUG_DISPLAYS, "CRTC %lu, output list: %d -> %lu.", crtc->id, n,
- crtc->outputs[n]);
+ xfsettings_dbg (XFSD_DEBUG_DISPLAYS, "CRTC %lu, output list[%d] -> %lu.", crtc->id,
+ crtc->noutput - 1, crtc->outputs[crtc->noutput - 1]);
}
@@ -759,9 +762,6 @@ xfce_displays_helper_channel_apply (XfceDisplaysHelper *helper,
}
- xfsettings_dbg (XFSD_DEBUG_DISPLAYS, "Desktop dimensions: %dx%d (px), %dx%d (mm).",
- width, height, mm_width, mm_height);
-
/* set the screen size only if it's really needed and valid */
if (width >= min_width && width <= max_width
&& height >= min_height && height <= max_height
@@ -769,8 +769,12 @@ xfce_displays_helper_channel_apply (XfceDisplaysHelper *helper,
|| height != gdk_screen_height ()
|| mm_width != gdk_screen_width_mm ()
|| mm_height != gdk_screen_height_mm ()))
+ {
+ xfsettings_dbg (XFSD_DEBUG_DISPLAYS, "Applying desktop dimensions: %dx%d (px), %dx%d (mm).",
+ width, height, mm_width, mm_height);
XRRSetScreenSize (xdisplay, GDK_WINDOW_XID (root_window),
width, height, mm_width, mm_height);
+ }
/* final loop, apply crtc changes */
for (m = 0; m < resources->ncrtc; ++m)
More information about the Xfce4-commits
mailing list