[mutter] Improve debug logging of Wayland windows
- From: Owen Taylor <otaylor src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] Improve debug logging of Wayland windows
- Date: Mon, 12 Oct 2015 13:55:32 +0000 (UTC)
commit 1ab8b854dff3452a708189e980ca84aebfc59984
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Mon Oct 12 08:04:55 2015 -0400
Improve debug logging of Wayland windows
Displaying all Wayland windows with the XID of 0x0 makes it hard
to figure out what is going on ... use the recently-added
window->stamp to show Wayland windows as W1/W2/W3...
src/core/window.c | 18 +++++++++++++++---
1 files changed, 15 insertions(+), 3 deletions(-)
---
diff --git a/src/core/window.c b/src/core/window.c
index 8cbbfaf..d075cab 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -763,10 +763,22 @@ meta_window_update_desc (MetaWindow *window)
{
g_clear_pointer (&window->desc, g_free);
- if (window->title)
- window->desc = g_strdup_printf ("0x%lx (%.10s)", window->xwindow, window->title);
+ if (window->client_type == META_WINDOW_CLIENT_TYPE_X11)
+ {
+ if (window->title)
+ window->desc = g_strdup_printf ("0x%lx (%.10s)", window->xwindow, window->title);
+ else
+ window->desc = g_strdup_printf ("0x%lx", window->xwindow);
+ }
else
- window->desc = g_strdup_printf ("0x%lx", window->xwindow);
+ {
+ guint64 small_stamp = window->stamp - G_GUINT64_CONSTANT(0x100000000);
+
+ if (window->title)
+ window->desc = g_strdup_printf ("W%" G_GUINT64_FORMAT " (%.10s)", small_stamp, window->title);
+ else
+ window->desc = g_strdup_printf ("W%" G_GUINT64_FORMAT , small_stamp);
+ }
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]