Drop use of GDK_DISABLE_DEPRECATED guards in gtk

We now use function attributes for deprecation so the build-breaking
guards are no longer needed.
This commit is contained in:
Matthias Clasen 2011-11-09 22:02:42 -05:00
parent b3e13bd0a8
commit a78ab0cfa1
16 changed files with 24 additions and 48 deletions

View File

@ -221,7 +221,6 @@
#include <gtk/gtkwidgetpath.h>
#include <gtk/gtkwindow.h>
#ifndef GTK_DISABLE_DEPRECATED
#include <gtk/deprecated/gtkfontsel.h>
#include <gtk/deprecated/gtkhandlebox.h>
#include <gtk/deprecated/gtkhbbox.h>
@ -240,7 +239,6 @@
#include <gtk/deprecated/gtkvscale.h>
#include <gtk/deprecated/gtkvscrollbar.h>
#include <gtk/deprecated/gtkvseparator.h>
#endif
#undef __GTK_H_INSIDE__

View File

@ -156,7 +156,6 @@ void gtk_assistant_set_page_title (GtkAssistant
const gchar * gtk_assistant_get_page_title (GtkAssistant *assistant,
GtkWidget *page);
#if !defined (GTK_DISABLE_DEPRECATED) || defined (GTK_COMPILATION)
GDK_DEPRECATED
void gtk_assistant_set_page_header_image (GtkAssistant *assistant,
GtkWidget *page,
@ -171,7 +170,6 @@ void gtk_assistant_set_page_side_image (GtkAssistant
GDK_DEPRECATED
GdkPixbuf *gtk_assistant_get_page_side_image (GtkAssistant *assistant,
GtkWidget *page);
#endif
void gtk_assistant_set_page_complete (GtkAssistant *assistant,
GtkWidget *page,

View File

@ -180,13 +180,11 @@ void gtk_binding_entry_remove (GtkBindingSet *binding_set,
guint keyval,
GdkModifierType modifiers);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED
void gtk_binding_set_add_path (GtkBindingSet *binding_set,
GtkPathType path_type,
const gchar *path_pattern,
GtkPathPriorityType priority);
#endif
G_END_DECLS

View File

@ -82,7 +82,6 @@ GtkWidget* gtk_button_new_with_label (const gchar *label);
GtkWidget* gtk_button_new_from_stock (const gchar *stock_id);
GtkWidget* gtk_button_new_with_mnemonic (const gchar *label);
void gtk_button_clicked (GtkButton *button);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED
void gtk_button_pressed (GtkButton *button);
GDK_DEPRECATED
@ -91,7 +90,6 @@ GDK_DEPRECATED
void gtk_button_enter (GtkButton *button);
GDK_DEPRECATED
void gtk_button_leave (GtkButton *button);
#endif
void gtk_button_set_relief (GtkButton *button,
GtkReliefStyle newstyle);

View File

@ -188,7 +188,6 @@ void gtk_cell_renderer_get_aligned_area (GtkCellRend
const GdkRectangle *cell_area,
GdkRectangle *aligned_area);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED_FOR(gtk_cell_renderer_get_preferred_size)
void gtk_cell_renderer_get_size (GtkCellRenderer *cell,
GtkWidget *widget,
@ -197,7 +196,6 @@ void gtk_cell_renderer_get_size (GtkCellRenderer *cell,
gint *y_offset,
gint *width,
gint *height);
#endif
void gtk_cell_renderer_render (GtkCellRenderer *cell,
cairo_t *cr,
GtkWidget *widget,

View File

@ -86,12 +86,10 @@ gboolean gtk_cell_view_get_fit_model (GtkCellView *cell_v
void gtk_cell_view_set_fit_model (GtkCellView *cell_view,
gboolean fit_model);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED_FOR(gtk_widget_get_preferred_size)
gboolean gtk_cell_view_get_size_of_row (GtkCellView *cell_view,
GtkTreePath *path,
GtkRequisition *requisition);
#endif
G_END_DECLS

View File

@ -130,10 +130,6 @@ GtkIconSet* gtk_icon_set_ref (GtkIconSet *icon_set);
void gtk_icon_set_unref (GtkIconSet *icon_set);
GtkIconSet* gtk_icon_set_copy (GtkIconSet *icon_set);
#if !defined (GTK_DISABLE_DEPRECATED) || defined (GTK_COMPILATION)
/* Get one of the icon variants in the set, creating the variant if
* necessary.
*/
GDK_DEPRECATED_FOR(gtk_icon_set_render_icon_pixbuf)
GdkPixbuf* gtk_icon_set_render_icon (GtkIconSet *icon_set,
GtkStyle *style,
@ -142,7 +138,6 @@ GdkPixbuf* gtk_icon_set_render_icon (GtkIconSet *icon_set,
GtkIconSize size,
GtkWidget *widget,
const gchar *detail);
#endif
void gtk_icon_set_add_source (GtkIconSet *icon_set,
const GtkIconSource *source);

View File

@ -210,14 +210,12 @@ GdkPixbuf * gtk_icon_info_load_symbolic_for_context (GtkIconInfo
GtkStyleContext *context,
gboolean *was_symbolic,
GError **error);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED_FOR(gtk_icon_info_load_symbol_for_context)
GdkPixbuf * gtk_icon_info_load_symbolic_for_style (GtkIconInfo *icon_info,
GtkStyle *style,
GtkStateType state,
gboolean *was_symbolic,
GError **error);
#endif
void gtk_icon_info_set_raw_coordinates (GtkIconInfo *icon_info,
gboolean raw_coordinates);

View File

@ -94,7 +94,6 @@ void gtk_layout_get_size (GtkLayout *layout,
guint *width,
guint *height);
#if !defined (GTK_DISABLE_DEPRECATED) || defined (GTK_COMPILATION)
GDK_DEPRECATED_FOR(gtk_scrollable_get_hadjustment)
GtkAdjustment* gtk_layout_get_hadjustment (GtkLayout *layout);
GDK_DEPRECATED_FOR(gtk_scrollable_get_vadjustment)
@ -106,7 +105,6 @@ GDK_DEPRECATED_FOR(gtk_scrollable_set_vadjustment)
void gtk_layout_set_vadjustment (GtkLayout *layout,
GtkAdjustment *adjustment);
#endif
G_END_DECLS

View File

@ -104,13 +104,11 @@ void gtk_menu_item_toggle_size_request (GtkMenuItem *menu_item,
gint *requisition);
void gtk_menu_item_toggle_size_allocate (GtkMenuItem *menu_item,
gint allocation);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED
void gtk_menu_item_set_right_justified (GtkMenuItem *menu_item,
gboolean right_justified);
GDK_DEPRECATED
gboolean gtk_menu_item_get_right_justified (GtkMenuItem *menu_item);
#endif /* GTK_DISABLE_DEPRECATED */
void gtk_menu_item_set_accel_path (GtkMenuItem *menu_item,
const gchar *accel_path);
const gchar * gtk_menu_item_get_accel_path (GtkMenuItem *menu_item);

View File

@ -188,10 +188,10 @@ void gtk_text_view_window_to_buffer_coords (GtkTextView *text_view,
gint *buffer_x,
gint *buffer_y);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED_FOR(gtk_scrollable_get_hadjustment)
GtkAdjustment* gtk_text_view_get_hadjustment (GtkTextView *text_view);
GDK_DEPRECATED_FOR(gtk_scrollable_get_vadjustment)
GtkAdjustment* gtk_text_view_get_vadjustment (GtkTextView *text_view);
#endif
GdkWindow* gtk_text_view_get_window (GtkTextView *text_view,
GtkTextWindowType win);

View File

@ -126,13 +126,12 @@ void gtk_tool_palette_add_drag_dest (GtkToolPa
GtkToolPaletteDragTargets targets,
GdkDragAction actions);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED_FOR(gtk_scrollable_get_hadjustment)
GtkAdjustment* gtk_tool_palette_get_hadjustment (GtkToolPalette *palette);
GDK_DEPRECATED_FOR(gtk_scrollable_get_vadjustment)
GtkAdjustment* gtk_tool_palette_get_vadjustment (GtkToolPalette *palette);
#endif
const GtkTargetEntry* gtk_tool_palette_get_drag_target_item (void) G_GNUC_CONST;
const GtkTargetEntry* gtk_tool_palette_get_drag_target_group (void) G_GNUC_CONST;

View File

@ -214,16 +214,17 @@ void gtk_tree_view_set_model (GtkTreeView
GtkTreeModel *model);
GtkTreeSelection *gtk_tree_view_get_selection (GtkTreeView *tree_view);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED_FOR(gtk_scrollable_get_hadjustment)
GtkAdjustment *gtk_tree_view_get_hadjustment (GtkTreeView *tree_view);
GDK_DEPRECATED_FOR(gtk_scrollable_set_hadjustment)
void gtk_tree_view_set_hadjustment (GtkTreeView *tree_view,
GtkAdjustment *adjustment);
GDK_DEPRECATED_FOR(gtk_scrollable_get_vadjustment)
GtkAdjustment *gtk_tree_view_get_vadjustment (GtkTreeView *tree_view);
GDK_DEPRECATED_FOR(gtk_scrollable_set_vadjustment)
void gtk_tree_view_set_vadjustment (GtkTreeView *tree_view,
GtkAdjustment *adjustment);
#endif
gboolean gtk_tree_view_get_headers_visible (GtkTreeView *tree_view);
void gtk_tree_view_set_headers_visible (GtkTreeView *tree_view,

View File

@ -126,11 +126,12 @@ typedef enum {
GType gtk_ui_manager_get_type (void) G_GNUC_CONST;
GtkUIManager *gtk_ui_manager_new (void);
#ifndef GTK_DISABLE_DEPRECATED
GDK_DEPRECATED
void gtk_ui_manager_set_add_tearoffs (GtkUIManager *manager,
gboolean add_tearoffs);
gboolean add_tearoffs);
GDK_DEPRECATED
gboolean gtk_ui_manager_get_add_tearoffs (GtkUIManager *manager);
#endif
void gtk_ui_manager_insert_action_group (GtkUIManager *manager,
GtkActionGroup *action_group,
gint pos);

View File

@ -75,16 +75,16 @@ GType gtk_viewport_get_type (void) G_GNUC_CONST;
GtkWidget* gtk_viewport_new (GtkAdjustment *hadjustment,
GtkAdjustment *vadjustment);
#if !defined (GTK_DISABLE_DEPRECATED) || defined (GTK_COMPILATION)
GDK_DEPRECATED_FOR(gtk_scrollable_get_hadjustment)
GtkAdjustment* gtk_viewport_get_hadjustment (GtkViewport *viewport);
GDK_DEPRECATED_FOR(gtk_scrollable_get_vadjustment)
GtkAdjustment* gtk_viewport_get_vadjustment (GtkViewport *viewport);
GDK_DEPRECATED_FOR(gtk_scrollable_set_hadjustment)
void gtk_viewport_set_hadjustment (GtkViewport *viewport,
GtkAdjustment *adjustment);
GtkAdjustment *adjustment);
GDK_DEPRECATED_FOR(gtk_scrollable_set_vadjustment)
void gtk_viewport_set_vadjustment (GtkViewport *viewport,
GtkAdjustment *adjustment);
#endif
GtkAdjustment *adjustment);
void gtk_viewport_set_shadow_type (GtkViewport *viewport,
GtkShadowType type);

View File

@ -483,10 +483,9 @@ void gtk_widget_queue_draw_region (GtkWidget *widget,
const cairo_region_t*region);
void gtk_widget_queue_resize (GtkWidget *widget);
void gtk_widget_queue_resize_no_redraw (GtkWidget *widget);
#ifndef GTK_DISABLE_DEPRECATED
void gtk_widget_size_request (GtkWidget *widget,
GtkRequisition *requisition);
#endif
GDK_DEPRECATED_FOR(gtk_widget_get_preferred_size)
void gtk_widget_size_request (GtkWidget *widget,
GtkRequisition *requisition);
void gtk_widget_size_allocate (GtkWidget *widget,
GtkAllocation *allocation);
@ -509,10 +508,9 @@ void gtk_widget_get_preferred_size (GtkWidget *w
GtkRequisition *minimum_size,
GtkRequisition *natural_size);
#ifndef GTK_DISABLE_DEPRECATED
void gtk_widget_get_child_requisition (GtkWidget *widget,
GtkRequisition *requisition);
#endif
GDK_DEPRECATED_FOR(gtk_widget_get_preferred_size)
void gtk_widget_get_child_requisition (GtkWidget *widget,
GtkRequisition *requisition);
void gtk_widget_add_accelerator (GtkWidget *widget,
const gchar *accel_signal,
GtkAccelGroup *accel_group,