summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog24
-rw-r--r--gtk/Makefile.am1
-rw-r--r--gtk/gtkclist.c4
-rw-r--r--gtk/gtkclist.h2
-rw-r--r--gtk/gtkctree.c8
-rw-r--r--gtk/gtkctree.h2
-rw-r--r--gtk/gtklist.c4
-rw-r--r--gtk/gtklist.h2
-rw-r--r--gtk/gtklistitem.c4
-rw-r--r--gtk/gtklistitem.h2
-rw-r--r--gtk/gtkpixmap.c8
-rw-r--r--gtk/gtkpixmap.h2
-rw-r--r--gtk/gtkprogress.c4
-rw-r--r--gtk/gtkprogress.h8
-rw-r--r--gtk/gtkprogressbar.c4
15 files changed, 58 insertions, 21 deletions
diff --git a/ChangeLog b/ChangeLog
index e92d382b26..5b674c2459 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,29 @@
2008-08-04 Michael Natterer <mitch@imendio.com>
+ * gtk/Makefile.am: build with GTK_DISABLE_DEPRECATED again.
+
+ Fix pltcheck.sh by restricting the visibility of deprecated
+ symbols to the places where they are actually used:
+
+ * gtk/gtkclist.c
+ * gtk/gtkctree.c
+ * gtk/gtklistitem.c
+ * gtk/gtklist.c
+ * gtk/gtkprogressbar.c
+ * gtk/gtkpixmap.c
+ * gtk/gtkprogress.c: #undef GTK_DISABLE_DEPRECATED and #define
+ __GTK_FOO_C__ on top instead of before including gtkaliasdef.c.
+
+ * gtk/gtkclist.h
+ * gtk/gtkctree.h
+ * gtk/gtklistitem.h
+ * gtk/gtklist.h
+ * gtk/gtkpixmap.h
+ * gtk/gtkprogress.h: make the headers visible if the respective
+ __GTK_FOO_C__ are defined.
+
+2008-08-04 Michael Natterer <mitch@imendio.com>
+
* gtk/gtkclist.c
* gtk/gtklist.c
* gtk/gtkoldeditable.c
diff --git a/gtk/Makefile.am b/gtk/Makefile.am
index 96380f121b..2cacd54907 100644
--- a/gtk/Makefile.am
+++ b/gtk/Makefile.am
@@ -35,6 +35,7 @@ INCLUDES = \
-I$(top_srcdir)/gdk-pixbuf -I../gdk-pixbuf \
-DGDK_PIXBUF_DISABLE_DEPRECATED \
-DGDK_DISABLE_DEPRECATED \
+ -DGTK_DISABLE_DEPRECATED \
-DGTK_FILE_SYSTEM_ENABLE_UNSUPPORTED \
-DGTK_PRINT_BACKEND_ENABLE_UNSUPPORTED \
$(GTK_DEBUG_FLAGS) \
diff --git a/gtk/gtkclist.c b/gtk/gtkclist.c
index 2517409ed0..35d9eb31a0 100644
--- a/gtk/gtkclist.c
+++ b/gtk/gtkclist.c
@@ -31,6 +31,8 @@
#include <string.h>
#undef GDK_DISABLE_DEPRECATED
+#undef GTK_DISABLE_DEPRECATED
+#define __GTK_CLIST_C__
#include <gdk/gdkkeysyms.h>
@@ -7790,6 +7792,4 @@ gtk_clist_set_button_actions (GtkCList *clist,
}
}
-#define __GTK_CLIST_C__
#include "gtkaliasdef.c"
-
diff --git a/gtk/gtkclist.h b/gtk/gtkclist.h
index 40a594d061..6e40eb2491 100644
--- a/gtk/gtkclist.h
+++ b/gtk/gtkclist.h
@@ -25,7 +25,7 @@
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
-#ifndef GTK_DISABLE_DEPRECATED
+#if !defined (GTK_DISABLE_DEPRECATED) || defined (__GTK_CLIST_C__) || defined (__GTK_CTREE_C__)
#ifndef __GTK_CLIST_H__
#define __GTK_CLIST_H__
diff --git a/gtk/gtkctree.c b/gtk/gtkctree.c
index f95b3db0f2..f514bc6880 100644
--- a/gtk/gtkctree.c
+++ b/gtk/gtkctree.c
@@ -28,10 +28,13 @@
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
-#undef GDK_DISABLE_DEPRECATED
-
#include "config.h"
#include <stdlib.h>
+
+#undef GDK_DISABLE_DEPRECATED
+#undef GTK_DISABLE_DEPRECATED
+#define __GTK_CTREE_C__
+
#include "gtkctree.h"
#include "gtkbindings.h"
#include "gtkmain.h"
@@ -6098,5 +6101,4 @@ gtk_ctree_node_get_type (void)
return our_type;
}
-#define __GTK_CTREE_C__
#include "gtkaliasdef.c"
diff --git a/gtk/gtkctree.h b/gtk/gtkctree.h
index 4e1551198a..1cf55236cc 100644
--- a/gtk/gtkctree.h
+++ b/gtk/gtkctree.h
@@ -28,7 +28,7 @@
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
-#ifndef GTK_DISABLE_DEPRECATED
+#if !defined (GTK_DISABLE_DEPRECATED) || defined (__GTK_CLIST_C__) || defined (__GTK_CTREE_C__)
#ifndef __GTK_CTREE_H__
#define __GTK_CTREE_H__
diff --git a/gtk/gtklist.c b/gtk/gtklist.c
index be651e951b..161a2c1474 100644
--- a/gtk/gtklist.c
+++ b/gtk/gtklist.c
@@ -27,6 +27,9 @@
#include "config.h"
#include <string.h> /* memset */
+#undef GTK_DISABLE_DEPRECATED
+#define __GTK_LIST_C__
+
#include "gtklist.h"
#include "gtklistitem.h"
#include "gtkmain.h"
@@ -2575,5 +2578,4 @@ gtk_list_drag_begin (GtkWidget *widget,
}
}
-#define __GTK_LIST_C__
#include "gtkaliasdef.c"
diff --git a/gtk/gtklist.h b/gtk/gtklist.h
index 08154859bb..873989e625 100644
--- a/gtk/gtklist.h
+++ b/gtk/gtklist.h
@@ -24,7 +24,7 @@
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
-#ifndef GTK_DISABLE_DEPRECATED
+#if !defined (GTK_DISABLE_DEPRECATED) || defined (__GTK_LIST_C__)
#ifndef __GTK_LIST_H__
#define __GTK_LIST_H__
diff --git a/gtk/gtklistitem.c b/gtk/gtklistitem.c
index 370c746ca0..6db5e7f661 100644
--- a/gtk/gtklistitem.c
+++ b/gtk/gtklistitem.c
@@ -28,6 +28,9 @@
#include <gdk/gdkkeysyms.h>
+#undef GTK_DISABLE_DEPRECATED
+#define __GTK_LIST_ITEM_C__
+
#include "gtkbindings.h"
#include "gtklabel.h"
#include "gtklistitem.h"
@@ -624,5 +627,4 @@ gtk_real_list_item_toggle (GtkItem *item)
}
}
-#define __GTK_LIST_ITEM_C__
#include "gtkaliasdef.c"
diff --git a/gtk/gtklistitem.h b/gtk/gtklistitem.h
index 545765d047..f2955a40b9 100644
--- a/gtk/gtklistitem.h
+++ b/gtk/gtklistitem.h
@@ -24,7 +24,7 @@
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
-#ifndef GTK_DISABLE_DEPRECATED
+#if !defined (GTK_DISABLE_DEPRECATED) || defined (__GTK_LIST_ITEM_C__)
#ifndef __GTK_LIST_ITEM_H__
#define __GTK_LIST_ITEM_H__
diff --git a/gtk/gtkpixmap.c b/gtk/gtkpixmap.c
index d088c41071..dc902fd1d3 100644
--- a/gtk/gtkpixmap.c
+++ b/gtk/gtkpixmap.c
@@ -27,10 +27,13 @@
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
-#undef GDK_DISABLE_DEPRECATED
-
#include "config.h"
#include <math.h>
+
+#undef GDK_DISABLE_DEPRECATED
+#undef GTK_DISABLE_DEPRECATED
+#define __GTK_PIXMAP_C__
+
#include "gtkcontainer.h"
#include "gtkpixmap.h"
#include "gtkintl.h"
@@ -277,5 +280,4 @@ build_insensitive_pixmap (GtkPixmap *gtkpixmap)
g_object_unref (G_OBJECT (stated));
}
-#define __GTK_PIXMAP_C__
#include "gtkaliasdef.c"
diff --git a/gtk/gtkpixmap.h b/gtk/gtkpixmap.h
index 747a04d957..bfad050e89 100644
--- a/gtk/gtkpixmap.h
+++ b/gtk/gtkpixmap.h
@@ -24,7 +24,7 @@
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
-#ifndef GTK_DISABLE_DEPRECATED
+#if !defined (GTK_DISABLE_DEPRECATED) || defined (__GTK_PIXMAP_C__)
#ifndef __GTK_PIXMAP_H__
#define __GTK_PIXMAP_H__
diff --git a/gtk/gtkprogress.c b/gtk/gtkprogress.c
index 7e528adb9c..3a1ac52c97 100644
--- a/gtk/gtkprogress.c
+++ b/gtk/gtkprogress.c
@@ -27,7 +27,10 @@
#include "config.h"
#include <math.h>
#include <string.h>
+
#undef GTK_DISABLE_DEPRECATED
+#define __GTK_PROGRESS_C__
+
#include "gtkprogress.h"
#include "gtkprivate.h"
#include "gtkintl.h"
@@ -707,5 +710,4 @@ gtk_progress_set_activity_mode (GtkProgress *progress,
}
}
-#define __GTK_PROGRESS_C__
#include "gtkaliasdef.c"
diff --git a/gtk/gtkprogress.h b/gtk/gtkprogress.h
index fbd86387fc..b47e8760f1 100644
--- a/gtk/gtkprogress.h
+++ b/gtk/gtkprogress.h
@@ -35,7 +35,7 @@
G_BEGIN_DECLS
-#if !defined (GTK_DISABLE_DEPRECATED) || defined (GTK_COMPILATION)
+#if !defined (GTK_DISABLE_DEPRECATED) || defined (__GTK_PROGRESS_C__) || defined (__GTK_PROGRESS_BAR_C__)
#define GTK_TYPE_PROGRESS (gtk_progress_get_type ())
#define GTK_PROGRESS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_PROGRESS, GtkProgress))
@@ -44,7 +44,7 @@ G_BEGIN_DECLS
#define GTK_IS_PROGRESS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PROGRESS))
#define GTK_PROGRESS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_PROGRESS, GtkProgressClass))
-#endif /* !GTK_DISABLE_DEPRECATED || GTK_COMPILATION */
+#endif /* !GTK_DISABLE_DEPRECATED */
typedef struct _GtkProgress GtkProgress;
typedef struct _GtkProgressClass GtkProgressClass;
@@ -84,7 +84,7 @@ struct _GtkProgressClass
* directly.
*/
-#if !defined (GTK_DISABLE_DEPRECATED) || defined (GTK_COMPILATION)
+#if !defined (GTK_DISABLE_DEPRECATED) || defined (__GTK_PROGRESS_C__) || defined (__GTK_PROGRESS_BAR_C__)
GType gtk_progress_get_type (void) G_GNUC_CONST;
void gtk_progress_set_show_text (GtkProgress *progress,
@@ -114,7 +114,7 @@ gdouble gtk_progress_get_current_percentage (GtkProgress *progress);
gdouble gtk_progress_get_percentage_from_value (GtkProgress *progress,
gdouble value);
-#endif /* !GTK_DISABLE_DEPRECATED || GTK_COMPILATION */
+#endif /* !GTK_DISABLE_DEPRECATED */
G_END_DECLS
diff --git a/gtk/gtkprogressbar.c b/gtk/gtkprogressbar.c
index bf690f2f36..96b316748a 100644
--- a/gtk/gtkprogressbar.c
+++ b/gtk/gtkprogressbar.c
@@ -28,6 +28,9 @@
#include <string.h>
+#undef GTK_DISABLE_DEPRECATED
+#define __GTK_PROGRESS_BAR_C__
+
#include "gtkprogressbar.h"
#include "gtkprivate.h"
#include "gtkintl.h"
@@ -1378,5 +1381,4 @@ gtk_progress_bar_get_ellipsize (GtkProgressBar *pbar)
return pbar->ellipsize;
}
-#define __GTK_PROGRESS_BAR_C__
#include "gtkaliasdef.c"