Changes to introspection generation to remove DOCTYPE and XML
[platform/core/uifw/at-spi2-atk.git] / atk-adaptor / remoteobject.c
1 /* AT-SPI : Assistive Technology Service Provider Interface
2  * Copyright 2001, 2002 Sun Microsystems Inc.,
3  * Copyright 2001, 2002 Ximian, Inc.
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13  * Library General Public License for more details.
14  *
15  * You should have received a copy of the GNU Library General Public
16  * License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18  * Boston, MA 02111-1307, USA.
19  */
20
21 #include <config.h>
22 #include "remoteobject.h"
23
24 Accessibility_Accessible
25 spi_remote_object_get_accessible (SpiRemoteObject *remote)
26 {
27   SpiRemoteObjectIface *iface;  
28
29   g_return_val_if_fail (SPI_IS_REMOTE_OBJECT (remote), CORBA_OBJECT_NIL);
30   
31   iface = SPI_REMOTE_OBJECT_GET_IFACE (remote);
32
33   if (!iface->get_accessible)
34     return CORBA_OBJECT_NIL;
35
36   return iface->get_accessible (remote);
37 }
38
39 GType
40 spi_remote_object_get_type (void)
41 {
42   static GType type = 0;
43
44   if (!type)
45     {
46       static const GTypeInfo typeInfo =
47       {
48         sizeof (SpiRemoteObjectIface),
49         (GBaseInitFunc) NULL,
50         (GBaseFinalizeFunc) NULL,
51         (GClassInitFunc) NULL,
52         (GClassFinalizeFunc) NULL,
53         NULL, 0, 0,
54         (GInstanceInitFunc) NULL,
55       };
56
57       type = g_type_register_static (G_TYPE_INTERFACE, "SpiRemoteObject", &typeInfo, 0) ;
58     }
59
60   return type;
61 }