summaryrefslogtreecommitdiff
path: root/gtk/gtktreeprivate.h
diff options
context:
space:
mode:
authorHidetoshi Tajima <tajima@src.gnome.org>2001-12-05 05:49:41 +0000
committerHidetoshi Tajima <tajima@src.gnome.org>2001-12-05 05:49:41 +0000
commit0657d7410b70d59dc100312742fb24f630451f0b (patch)
tree977defc0437305c6e1ebbb83212c9d490a53e909 /gtk/gtktreeprivate.h
parent9605ec8a03f317f29bf9dcfd3cbb9cf79de60079 (diff)
downloadgdk-pixbuf-0657d7410b70d59dc100312742fb24f630451f0b.tar.gz
restore the else case of #ifdef __GNUC__ #66225
* gtk/gtktreeprivate.h: restore the else case of #ifdef __GNUC__ #66225
Diffstat (limited to 'gtk/gtktreeprivate.h')
-rw-r--r--gtk/gtktreeprivate.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/gtk/gtktreeprivate.h b/gtk/gtktreeprivate.h
index 0ce4ac994..030535e6f 100644
--- a/gtk/gtktreeprivate.h
+++ b/gtk/gtktreeprivate.h
@@ -184,6 +184,8 @@ struct _GtkTreeViewPrivate
GtkDestroyNotify search_destroy;
};
+#ifdef __GNUC__
+
#define TREE_VIEW_INTERNAL_ASSERT(expr, ret) G_STMT_START{ \
if (!(expr)) \
{ \
@@ -218,6 +220,41 @@ struct _GtkTreeViewPrivate
return; \
}; }G_STMT_END
+#else
+
+#define TREE_VIEW_INTERNAL_ASSERT(expr, ret) G_STMT_START{ \
+ if (!(expr)) \
+ { \
+ g_log (G_LOG_DOMAIN, \
+ G_LOG_LEVEL_CRITICAL, \
+ "file %s: line %d: assertion `%s' failed.\n" \
+ "There is a disparity between the internal view of the GtkTreeView,\n" \
+ "and the GtkTreeModel. This generally means that the model has changed\n"\
+ "without letting the view know. Any display from now on is likely to\n" \
+ "be incorrect.\n", \
+ __FILE__, \
+ __LINE__, \
+ #expr); \
+ return ret; \
+ }; }G_STMT_END
+
+#define TREE_VIEW_INTERNAL_ASSERT_VOID(expr) G_STMT_START{ \
+ if (!(expr)) \
+ { \
+ g_log (G_LOG_DOMAIN, \
+ G_LOG_LEVEL_CRITICAL, \
+ "file %s: line %d: assertion '%s' failed.\n" \
+ "There is a disparity between the internal view of the GtkTreeView,\n" \
+ "and the GtkTreeModel. This generally means that the model has changed\n"\
+ "without letting the view know. Any display from now on is likely to\n" \
+ "be incorrect.\n", \
+ __FILE__, \
+ __LINE__, \
+ #expr); \
+ return; \
+ }; }G_STMT_END
+#endif
+
/* functions that shouldn't be exported */
void _gtk_tree_selection_internal_select_node (GtkTreeSelection *selection,