Commit 5ee19bda authored by Javier Jardón's avatar Javier Jardón

Use accessor functions to access GtkAccesible variables

parent a6e0fb92
......@@ -2322,7 +2322,7 @@ gtk_assistant_accessible_get_n_children (AtkObject *accessible)
GtkAssistant *assistant;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (accessible)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible));
if (!widget)
return 0;
......@@ -2344,7 +2344,7 @@ gtk_assistant_accessible_ref_child (AtkObject *accessible,
AtkObject *obj;
const gchar *title;
widget = GTK_ACCESSIBLE (accessible)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible));
if (!widget)
return NULL;
......
......@@ -8968,7 +8968,7 @@ gtk_icon_view_accessible_get_n_children (AtkObject *accessible)
GtkIconView *icon_view;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (accessible)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible));
if (!widget)
return 0;
......@@ -9008,7 +9008,7 @@ gtk_icon_view_accessible_ref_child (AtkObject *accessible,
AtkObject *obj;
GtkIconViewItemAccessible *a11y_item;
widget = GTK_ACCESSIBLE (accessible)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible));
if (!widget)
return NULL;
......@@ -9066,7 +9066,7 @@ gtk_icon_view_accessible_traverse_items (GtkIconViewAccessible *view,
GtkWidget *widget;
gboolean act_on_item;
widget = GTK_ACCESSIBLE (view)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (view));
if (widget == NULL)
return;
......@@ -9188,7 +9188,7 @@ gtk_icon_view_accessible_model_row_changed (GtkTreeModel *tree_model,
if (a11y_item)
{
widget = GTK_ACCESSIBLE (atk_obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (atk_obj));
icon_view = GTK_ICON_VIEW (widget);
item = a11y_item->item;
......@@ -9547,9 +9547,12 @@ gtk_icon_view_accessible_destroyed (GtkWidget *widget,
static void
gtk_icon_view_accessible_connect_widget_destroyed (GtkAccessible *accessible)
{
if (accessible->widget)
GtkWidget *widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible));
if (widget)
{
g_signal_connect_after (accessible->widget,
g_signal_connect_after (widget,
"destroy",
G_CALLBACK (gtk_icon_view_accessible_destroyed),
accessible);
......@@ -9590,7 +9593,7 @@ gtk_icon_view_accessible_ref_accessible_at_point (AtkComponent *component,
GtkIconViewItem *item;
gint x_pos, y_pos;
widget = GTK_ACCESSIBLE (component)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (component));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -9618,7 +9621,7 @@ gtk_icon_view_accessible_add_selection (AtkSelection *selection,
GtkIconView *icon_view;
GtkIconViewItem *item;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
return FALSE;
......@@ -9640,7 +9643,7 @@ gtk_icon_view_accessible_clear_selection (AtkSelection *selection)
GtkWidget *widget;
GtkIconView *icon_view;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
return FALSE;
......@@ -9659,7 +9662,7 @@ gtk_icon_view_accessible_ref_selection (AtkSelection *selection,
GtkIconView *icon_view;
GtkIconViewItem *item;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
return NULL;
......@@ -9691,7 +9694,7 @@ gtk_icon_view_accessible_get_selection_count (AtkSelection *selection)
GList *l;
gint count;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
return 0;
......@@ -9720,7 +9723,7 @@ gtk_icon_view_accessible_is_child_selected (AtkSelection *selection,
GtkIconView *icon_view;
GtkIconViewItem *item;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
return FALSE;
......@@ -9743,7 +9746,7 @@ gtk_icon_view_accessible_remove_selection (AtkSelection *selection,
GList *l;
gint count;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
return FALSE;
......@@ -9774,7 +9777,7 @@ gtk_icon_view_accessible_select_all_selection (AtkSelection *selection)
GtkWidget *widget;
GtkIconView *icon_view;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
return FALSE;
......
......@@ -475,7 +475,7 @@ gtk_spinner_accessible_image_get_size (AtkImage *image,
{
GtkWidget *widget;
widget = GTK_ACCESSIBLE (image)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (image));
if (!widget)
{
*width = *height = 0;
......
......@@ -60,7 +60,7 @@ gail_box_ref_state_set (AtkObject *accessible)
GtkWidget *widget;
state_set = ATK_OBJECT_CLASS (gail_box_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;
......
......@@ -198,7 +198,7 @@ gail_button_get_name (AtkObject *obj)
GtkWidget *widget;
GtkWidget *child;
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
/*
* State is defunct
......@@ -459,7 +459,7 @@ gail_button_do_action (AtkAction *action,
GailButton *button;
gboolean return_value = TRUE;
widget = GTK_ACCESSIBLE (action)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (action));
if (widget == NULL)
/*
* State is defunct
......@@ -501,7 +501,7 @@ idle_do_action (gpointer data)
gail_button = GAIL_BUTTON (data);
gail_button->action_idle_handler = 0;
widget = GTK_ACCESSIBLE (gail_button)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (gail_button));
tmp_event.button.type = GDK_BUTTON_RELEASE;
tmp_event.button.window = widget->window;
tmp_event.button.button = 1;
......@@ -652,7 +652,7 @@ gail_button_get_keybinding (AtkAction *action,
GtkWidget *label;
guint key_val;
widget = GTK_ACCESSIBLE (button)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (button));
if (widget == NULL)
/*
* State is defunct
......@@ -685,10 +685,7 @@ gail_button_get_keybinding (AtkAction *action,
target = atk_relation_get_target (relation);
target_object = g_ptr_array_index (target, 0);
if (GTK_IS_ACCESSIBLE (target_object))
{
label = GTK_ACCESSIBLE (target_object)->widget;
}
label = gtk_accessible_get_widget (GTK_ACCESSIBLE (target_object));
}
g_object_unref (set);
}
......@@ -809,7 +806,7 @@ gail_button_get_n_children (AtkObject* obj)
g_return_val_if_fail (GAIL_IS_BUTTON (obj), 0);
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
/*
* State is defunct
......@@ -840,7 +837,7 @@ gail_button_ref_child (AtkObject *obj,
g_return_val_if_fail (GAIL_IS_BUTTON (obj), NULL);
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
/*
* State is defunct
......@@ -883,7 +880,7 @@ gail_button_ref_state_set (AtkObject *obj)
GtkWidget *widget;
state_set = ATK_OBJECT_CLASS (gail_button_parent_class)->ref_state_set (obj);
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
return state_set;
......@@ -980,8 +977,7 @@ gail_button_get_image_description (AtkImage *image) {
GtkImage *button_image;
AtkObject *obj;
widget = GTK_ACCESSIBLE (image)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (image));
if (widget == NULL)
/*
* State is defunct
......@@ -1009,7 +1005,7 @@ gail_button_get_image_position (AtkImage *image,
GtkImage *button_image;
AtkObject *obj;
widget = GTK_ACCESSIBLE (image)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (image));
if (widget == NULL)
{
......@@ -1044,7 +1040,7 @@ gail_button_get_image_size (AtkImage *image,
GtkImage *button_image;
AtkObject *obj;
widget = GTK_ACCESSIBLE (image)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (image));
if (widget == NULL)
{
......@@ -1078,7 +1074,7 @@ gail_button_set_image_description (AtkImage *image,
GtkImage *button_image;
AtkObject *obj;
widget = GTK_ACCESSIBLE (image)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (image));
if (widget == NULL)
/*
......@@ -1124,7 +1120,8 @@ gail_button_get_text (AtkText *text,
GailButton *button;
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;
......@@ -1159,9 +1156,9 @@ gail_button_get_text_before_offset (AtkText *text,
GtkWidget *widget;
GtkWidget *label;
GailButton *button;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -1191,9 +1188,9 @@ gail_button_get_text_at_offset (AtkText *text,
GtkWidget *widget;
GtkWidget *label;
GailButton *button;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
widget = GTK_ACCESSIBLE (text)->widget;
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -1224,8 +1221,8 @@ gail_button_get_text_after_offset (AtkText *text,
GtkWidget *label;
GailButton *button;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
{
/* State is defunct */
......@@ -1253,7 +1250,8 @@ gail_button_get_character_count (AtkText *text)
GtkWidget *widget;
GtkWidget *label;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return 0;
......@@ -1280,8 +1278,8 @@ gail_button_get_character_extents (AtkText *text,
PangoRectangle char_rect;
gint index, x_layout, y_layout;
const gchar *label_text;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
......@@ -1312,10 +1310,12 @@ gail_button_get_offset_at_point (AtkText *text,
gint index, x_layout, y_layout;
const gchar *label_text;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return -1;
label = get_label_from_button (widget, 0, FALSE);
if (!GTK_IS_LABEL(label))
......@@ -1350,7 +1350,8 @@ gail_button_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;
......@@ -1392,7 +1393,8 @@ gail_button_get_default_attributes (AtkText *text)
GtkWidget *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;
......@@ -1417,7 +1419,8 @@ gail_button_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';
......
......@@ -111,7 +111,7 @@ gail_check_menu_item_ref_state_set (AtkObject *accessible)
GtkWidget *widget;
state_set = ATK_OBJECT_CLASS (gail_check_menu_item_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;
......
......@@ -108,7 +108,7 @@ gail_check_sub_menu_item_ref_state_set (AtkObject *accessible)
GtkWidget *widget;
state_set = ATK_OBJECT_CLASS (gail_check_sub_menu_item_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;
......
......@@ -161,7 +161,7 @@ gail_combo_box_get_name (AtkObject *obj)
if (name)
return name;
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
/*
* State is defunct
......@@ -206,7 +206,8 @@ gail_combo_box_get_n_children (AtkObject* obj)
g_return_val_if_fail (GAIL_IS_COMBO_BOX (obj), 0);
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
/*
* State is defunct
......@@ -230,7 +231,7 @@ gail_combo_box_ref_child (AtkObject *obj,
g_return_val_if_fail (GAIL_IS_COMBO_BOX (obj), NULL);
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
/*
......@@ -277,7 +278,8 @@ gail_combo_box_do_action (AtkAction *action,
GailComboBox *combo_box;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (action)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (action));
if (widget == NULL)
/*
* State is defunct
......@@ -311,7 +313,8 @@ idle_do_action (gpointer data)
gail_combo_box = GAIL_COMBO_BOX (data);
gail_combo_box->action_idle_handler = 0;
widget = GTK_ACCESSIBLE (gail_combo_box)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (gail_combo_box));
if (widget == NULL || /* State is defunct */
!gtk_widget_get_sensitive (widget) || !gtk_widget_get_visible (widget))
return FALSE;
......@@ -319,7 +322,7 @@ idle_do_action (gpointer data)
combo_box = GTK_COMBO_BOX (widget);
popup = gtk_combo_box_get_popup_accessible (combo_box);
do_popup = !gtk_widget_get_mapped (GTK_ACCESSIBLE (popup)->widget);
do_popup = !gtk_widget_get_mapped (gtk_accessible_get_widget (GTK_ACCESSIBLE (popup)));
if (do_popup)
gtk_combo_box_popup (combo_box);
else
......@@ -371,7 +374,7 @@ gail_combo_box_get_keybinding (AtkAction *action,
guint key_val;
combo_box = GAIL_COMBO_BOX (action);
widget = GTK_ACCESSIBLE (combo_box)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (combo_box));
if (widget == NULL)
return NULL;
set = atk_object_ref_relation_set (ATK_OBJECT (action));
......@@ -383,10 +386,7 @@ gail_combo_box_get_keybinding (AtkAction *action,
{
target = atk_relation_get_target (relation);
target_object = g_ptr_array_index (target, 0);
if (GTK_IS_ACCESSIBLE (target_object))
{
label = GTK_ACCESSIBLE (target_object)->widget;
}
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (target_object));
}
g_object_unref (set);
if (GTK_IS_LABEL (label))
......@@ -456,7 +456,8 @@ gail_combo_box_add_selection (AtkSelection *selection,
GtkComboBox *combo_box;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
/*
* State is defunct
......@@ -475,7 +476,8 @@ gail_combo_box_clear_selection (AtkSelection *selection)
GtkComboBox *combo_box;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
/*
* State is defunct
......@@ -497,7 +499,8 @@ gail_combo_box_ref_selection (AtkSelection *selection,
AtkObject *obj;
gint index;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
/*
* State is defunct
......@@ -523,7 +526,8 @@ gail_combo_box_get_selection_count (AtkSelection *selection)
GtkComboBox *combo_box;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
/*
* State is defunct
......@@ -543,7 +547,8 @@ gail_combo_box_is_child_selected (AtkSelection *selection,
gint j;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (selection)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (selection));
if (widget == NULL)
/*
* State is defunct
......
......@@ -79,7 +79,7 @@ gail_container_get_n_children (AtkObject* obj)
g_return_val_if_fail (GAIL_IS_CONTAINER (obj), count);
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
return 0;
......@@ -100,7 +100,8 @@ gail_container_ref_child (AtkObject *obj,
g_return_val_if_fail (GAIL_IS_CONTAINER (obj), NULL);
g_return_val_if_fail ((i >= 0), NULL);
widget = GTK_ACCESSIBLE (obj)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
if (widget == NULL)
return NULL;
......
......@@ -377,8 +377,8 @@ gail_entry_ref_state_set (AtkObject *accessible)
GtkWidget *widget;
state_set = ATK_OBJECT_CLASS (gail_entry_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;
......@@ -423,7 +423,7 @@ gail_entry_get_text (AtkText *text,
{
GtkWidget *widget;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -441,7 +441,7 @@ gail_entry_get_text_before_offset (AtkText *text,
GtkWidget *widget;
GtkEntry *entry;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -464,7 +464,7 @@ gail_entry_get_text_at_offset (AtkText *text,
GtkWidget *widget;
GtkEntry *entry;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -487,7 +487,7 @@ gail_entry_get_text_after_offset (AtkText *text,
GtkWidget *widget;
GtkEntry *entry;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -506,7 +506,7 @@ gail_entry_get_character_count (AtkText *text)
GtkEntry *entry;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return 0;
......@@ -521,7 +521,7 @@ gail_entry_get_caret_offset (AtkText *text)
GtkEntry *entry;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return 0;
......@@ -537,7 +537,7 @@ gail_entry_set_caret_offset (AtkText *text, gint offset)
GtkEntry *entry;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return FALSE;
......@@ -559,7 +559,7 @@ gail_entry_get_run_attributes (AtkText *text,
AtkAttributeSet *at_set = NULL;
GtkTextDirection dir;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -590,7 +590,7 @@ gail_entry_get_default_attributes (AtkText *text)
GtkEntry *entry;
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;
......@@ -618,7 +618,7 @@ gail_entry_get_character_extents (AtkText *text,
gint index, cursor_index, x_layout, y_layout;
const gchar *entry_text;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return;
......@@ -647,8 +647,8 @@ gail_entry_get_offset_at_point (AtkText *text,
GtkEntry *entry;
gint index, cursor_index, x_layout, y_layout;
const gchar *entry_text;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return -1;
......@@ -688,7 +688,7 @@ gail_entry_get_n_selections (AtkText *text)
GtkWidget *widget;
gint select_start, select_end;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return -1;
......@@ -713,7 +713,7 @@ gail_entry_get_selection (AtkText *text,
GtkEntry *entry;
GtkWidget *widget;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return NULL;
......@@ -742,7 +742,7 @@ gail_entry_add_selection (AtkText *text,
GtkWidget *widget;
gint select_start, select_end;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return FALSE;
......@@ -772,7 +772,7 @@ gail_entry_remove_selection (AtkText *text,
GtkWidget *widget;
gint select_start, select_end, caret_pos;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return FALSE;
......@@ -807,7 +807,7 @@ gail_entry_set_selection (AtkText *text,
GtkWidget *widget;
gint select_start, select_end;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return FALSE;
......@@ -852,7 +852,7 @@ gail_entry_set_text_contents (AtkEditableText *text,
GtkWidget *widget;
GtkEditable *editable;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return;
......@@ -875,7 +875,7 @@ gail_entry_insert_text (AtkEditableText *text,
GtkWidget *widget;
GtkEditable *editable;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return;
......@@ -900,7 +900,7 @@ gail_entry_copy_text (AtkEditableText *text,
gchar *str;
GtkClipboard *clipboard;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return;
......@@ -924,7 +924,7 @@ gail_entry_cut_text (AtkEditableText *text,
gchar *str;
GtkClipboard *clipboard;
widget = GTK_ACCESSIBLE (text)->widget;
widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (text));
if (widget == NULL)
/* State is defunct */
return;
......@@ -949,7 +949,7 @@ gail_entry_delete_text (AtkEditableText *text,
GtkWidget *widget;
GtkEditable *editable;
widget = GTK_ACCESSIBLE<