diff options
author | Matthias Clasen <mclasen@redhat.com> | 2011-06-23 18:41:47 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2011-07-05 16:08:07 -0400 |
commit | 1b8c38f6e133974b0097088bf019ce2bbb1a46a4 (patch) | |
tree | 01eb92bdfb63449d978b7c794f0d7f02896fbc98 /gtk | |
parent | 3edebfb81c7d013641dd641886830851e446adf3 (diff) | |
download | gtk+-1b8c38f6e133974b0097088bf019ce2bbb1a46a4.tar.gz |
GtkHSV: set a suitable role for the accessible
The consensus of the accessibility team was that 'color chooser'
fits best for this. Update tests to match.
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/gtkhsv.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gtk/gtkhsv.c b/gtk/gtkhsv.c index 913f6dfdff..78be5921ca 100644 --- a/gtk/gtkhsv.c +++ b/gtk/gtkhsv.c @@ -124,6 +124,7 @@ static gboolean gtk_hsv_focus (GtkWidget *widget, GtkDirectionType direction); static void gtk_hsv_move (GtkHSV *hsv, GtkDirectionType dir); +static AtkObject *gtk_hsv_get_accessible (GtkWidget *widget); static guint hsv_signals[LAST_SIGNAL]; @@ -154,6 +155,7 @@ gtk_hsv_class_init (GtkHSVClass *class) widget_class->draw = gtk_hsv_draw; widget_class->focus = gtk_hsv_focus; widget_class->grab_broken_event = gtk_hsv_grab_broken; + widget_class->get_accessible = gtk_hsv_get_accessible; hsv_class->move = gtk_hsv_move; @@ -1618,3 +1620,16 @@ gtk_hsv_move (GtkHSV *hsv, gtk_hsv_set_color (hsv, hue, sat, val); } + +static AtkObject * +gtk_hsv_get_accessible (GtkWidget *widget) +{ + AtkObject *obj; + + obj = GTK_WIDGET_CLASS (gtk_hsv_parent_class)->get_accessible (widget); + + atk_object_set_role (obj, ATK_ROLE_COLOR_CHOOSER); + + return obj; +} + |