[gtk+/wip/matthiasc/gsk-renderer: 4/5] gsk: Add debug macros that trigger on two conditions
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/matthiasc/gsk-renderer: 4/5] gsk: Add debug macros that trigger on two conditions
- Date: Wed, 3 Aug 2016 02:02:33 +0000 (UTC)
commit 3e963554bd3da2a35bd9f1c5ad0f9fbb9800ee8e
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Aug 2 21:56:17 2016 -0400
gsk: Add debug macros that trigger on two conditions
This will be useful in the following commits.
gsk/gskdebugprivate.h | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/gsk/gskdebugprivate.h b/gsk/gskdebugprivate.h
index f624dd1..5ab23b2 100644
--- a/gsk/gskdebugprivate.h
+++ b/gsk/gskdebugprivate.h
@@ -26,6 +26,7 @@ gboolean gsk_check_rendering_flags (GskRenderingMode flags);
#ifdef G_ENABLE_DEBUG
#define GSK_DEBUG_CHECK(type) G_UNLIKELY (gsk_check_debug_flags (GSK_DEBUG_ ## type))
+#define GSK_DEBUG_CHECK2(type1,type2) G_UNLIKELY (gsk_check_debug_flags (GSK_DEBUG_ ## type1 | GSK_DEBUG_
## type2))
#define GSK_RENDER_MODE_CHECK(type) G_UNLIKELY (gsk_check_rendering_flags (GSK_RENDERING_MODE_ ## type))
#define GSK_NOTE(type,action) G_STMT_START { \
@@ -33,11 +34,17 @@ gboolean gsk_check_rendering_flags (GskRenderingMode flags);
action; \
} } G_STMT_END
+#define GSK_NOTE2(type1,type2,action) G_STMT_START { \
+ if (GSK_DEBUG_CHECK2 (type1, type2)) { \
+ action; \
+ } } G_STMT_END
#else
#define GSK_RENDER_MODE_CHECK(type) 0
#define GSK_DEBUG_CHECK(type) 0
+#define GSK_DEBUG_CHECK2(type1,type2) 0
#define GSK_NOTE(type,action)
+#define GSK_NOTE2(type1,type2,action)
#endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]