X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=modules%2Fother%2Fgail%2Fgaillabel.c;h=1961e8842121cc920494371393dec3a4cd99f38f;hb=5e2b5680a491da87cb8f22ca90df09248f3884e6;hp=c6d02788b9815812d38e66cd90d885c35edfee21;hpb=0de8601327d541f644dc1882c99f44551870a7ab;p=~andy%2Fgtk diff --git a/modules/other/gail/gaillabel.c b/modules/other/gail/gaillabel.c index c6d02788b..1961e8842 100644 --- a/modules/other/gail/gaillabel.c +++ b/modules/other/gail/gaillabel.c @@ -21,8 +21,6 @@ #include -#undef GTK_DISABLE_DEPRECATED - #include #include "gaillabel.h" #include "gailwindow.h" @@ -44,7 +42,7 @@ static void atk_text_interface_init (AtkTextIface *iface); /* atkobject.h */ -static G_CONST_RETURN gchar* gail_label_get_name (AtkObject *accessible); +static const gchar* gail_label_get_name (AtkObject *accessible); static AtkStateSet* gail_label_ref_state_set (AtkObject *accessible); static AtkRelationSet* gail_label_ref_relation_set (AtkObject *accessible); @@ -219,7 +217,7 @@ notify_name_change (AtkObject *atk_obj) GtkWidget *widget; GObject *gail_obj; - widget = GTK_ACCESSIBLE (atk_obj)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (atk_obj)); if (widget == NULL) /* * State is defunct @@ -423,7 +421,7 @@ gail_label_ref_state_set (AtkObject *accessible) GtkWidget *widget; state_set = ATK_OBJECT_CLASS (gail_label_parent_class)->ref_state_set (accessible); - widget = GTK_ACCESSIBLE (accessible)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible)); if (widget == NULL) return state_set; @@ -441,7 +439,7 @@ gail_label_ref_relation_set (AtkObject *obj) g_return_val_if_fail (GAIL_IS_LABEL (obj), NULL); - widget = GTK_ACCESSIBLE (obj)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj)); if (widget == NULL) /* * State is defunct @@ -502,7 +500,7 @@ gail_label_ref_relation_set (AtkObject *obj) { GtkWidget *temp_widget; - temp_widget = GTK_BIN (list->data)->child; + temp_widget = gtk_bin_get_child (GTK_BIN (list->data)); if (GTK_IS_BUTTON (temp_widget)) mnemonic_widget = temp_widget; } @@ -531,10 +529,10 @@ gail_label_ref_relation_set (AtkObject *obj) return relation_set; } -static G_CONST_RETURN gchar* +static const gchar* gail_label_get_name (AtkObject *accessible) { - G_CONST_RETURN gchar *name; + const gchar *name; g_return_val_if_fail (GAIL_IS_LABEL (accessible), NULL); @@ -548,7 +546,7 @@ gail_label_get_name (AtkObject *accessible) */ GtkWidget *widget; - widget = GTK_ACCESSIBLE (accessible)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible)); if (widget == NULL) /* * State is defunct @@ -595,7 +593,7 @@ gail_label_get_text (AtkText *text, const gchar *label_text; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return NULL; @@ -625,7 +623,7 @@ gail_label_get_text_before_offset (AtkText *text, GtkWidget *widget; GtkLabel *label; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ @@ -649,7 +647,7 @@ gail_label_get_text_at_offset (AtkText *text, GtkWidget *widget; GtkLabel *label; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ @@ -673,7 +671,7 @@ gail_label_get_text_after_offset (AtkText *text, GtkWidget *widget; GtkLabel *label; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) { @@ -695,7 +693,7 @@ gail_label_get_character_count (AtkText *text) GtkWidget *widget; GtkLabel *label; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return 0; @@ -717,7 +715,7 @@ gail_label_set_caret_offset (AtkText *text, GtkWidget *widget; GtkLabel *label; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return 0; @@ -742,7 +740,7 @@ gail_label_get_n_selections (AtkText *text) GtkLabel *label; gint start, end; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return 0; @@ -767,7 +765,7 @@ gail_label_get_selection (AtkText *text, GtkWidget *widget; GtkLabel *label; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return NULL; @@ -803,7 +801,7 @@ gail_label_add_selection (AtkText *text, GtkLabel *label; gint start, end; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return FALSE; @@ -830,7 +828,7 @@ gail_label_remove_selection (AtkText *text, GtkLabel *label; gint start, end; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return FALSE; @@ -862,7 +860,7 @@ gail_label_set_selection (AtkText *text, GtkLabel *label; gint start, end; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return FALSE; @@ -899,7 +897,7 @@ gail_label_get_character_extents (AtkText *text, const gchar *label_text; gint index, x_layout, y_layout; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ @@ -927,7 +925,7 @@ gail_label_get_offset_at_point (AtkText *text, const gchar *label_text; gint index, x_layout, y_layout; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return -1; @@ -962,7 +960,7 @@ gail_label_get_run_attributes (AtkText *text, GtkJustification justify; GtkTextDirection dir; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return NULL; @@ -1001,7 +999,7 @@ gail_label_get_default_attributes (AtkText *text) GtkLabel *label; AtkAttributeSet *at_set = NULL; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return NULL; @@ -1023,7 +1021,7 @@ gail_label_get_character_at_offset (AtkText *text, const gchar *string; gchar *index; - widget = GTK_ACCESSIBLE (text)->widget; + widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text)); if (widget == NULL) /* State is defunct */ return '\0';