1 /* GAIL - The GNOME Accessibility Implementation Library
2 * Copyright 2001 Sun Microsystems Inc.
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 * Boston, MA 02111-1307, USA.
24 #include "gailframe.h"
26 static void gail_frame_class_init (GailFrameClass *klass);
27 static void gail_frame_init (GailFrame *frame);
28 static void gail_frame_initialize (AtkObject *accessible,
30 static const gchar* gail_frame_get_name (AtkObject *obj);
32 G_DEFINE_TYPE (GailFrame, gail_frame, GAIL_TYPE_CONTAINER)
35 gail_frame_class_init (GailFrameClass *klass)
37 AtkObjectClass *class = ATK_OBJECT_CLASS (klass);
39 class->initialize = gail_frame_initialize;
40 class->get_name = gail_frame_get_name;
44 gail_frame_init (GailFrame *frame)
49 gail_frame_initialize (AtkObject *accessible,
52 ATK_OBJECT_CLASS (gail_frame_parent_class)->initialize (accessible, data);
54 accessible->role = ATK_ROLE_PANEL;
58 gail_frame_get_name (AtkObject *obj)
61 g_return_val_if_fail (GAIL_IS_FRAME (obj), NULL);
63 name = ATK_OBJECT_CLASS (gail_frame_parent_class)->get_name (obj);
71 * Get the text on the label
75 widget = gtk_accessible_get_widget (GTK_ACCESSIBLE (obj));
83 return gtk_frame_get_label (GTK_FRAME (widget));