+2001-07-31 Bill Haneman <bill.haneman@sun.com>
+
+ * libspi/accessible.c
+ * libspi/desktop.c
+ * libspi/registry.c : changed to use bonobo_object instead of bonobo_x_object
+ (since the two are now equivalent in libbonobo)
+ * idl/Action.idl
+ * idl/Component.idl
+ * idl/Hyperlink.idl
+ * idl/Image.idl
+ * idl/Selection.idl
+ * idl/Table.idl
+ * idl/Text.idl
+ * idl/Value.idl : changed these 'secondary' interfaces to inherit from
+ Bonobo::Unknown as does Accessibility::Accessible.
+ * idl/StreamableContent.idl : as above, and replaced internal InputStream
+ interface with Bonobo::Stream, since it was redundant with it.
+ (The Stream returned by a StreamableContext object is expected to
+ implement only a subset of Bonobo::Stream)
+
2001-07-28 Anders Carlsson <andersca@gnome.org>
- * libspi/accessible.c (accessible_object_finalize): Change
- g_free to g_object_unref since the AtkObject is a GObject.
+ * libspi/accessible.c (accessible_object_finalize): Change
+ g_free to g_object_unref since the AtkObject is a GObject.
2001-07-30 Bill Haneman <bill.haneman@sun.com>
module Accessibility {
- interface Action {
+ interface Action : Bonobo::Unknown {
/**
* getNActions:
module Accessibility {
- interface Component {
+ interface Component : Bonobo::Unknown {
boolean contains (in long x, in long y);
Accessible getAccessibleAtPoint (in long x, in long y);
module Accessibility {
- interface Hyperlink {
+ interface Hyperlink : Bonobo::Unknown {
Accessible getAnchor (in long i);
Accessible getObject (in long i);
long getStartIndex ();
module Accessibility {
- interface Hypertext {
+ interface Hypertext : Text {
long getNLinks ();
Hyperlink getLink (in long linkIndex);
long getLinkIndex (in long characterIndex);
module Accessibility {
- interface Image {
+ interface Image : Bonobo::Unknown {
string getImageDescription ();
long getImageHeight ();
long getImageWidth ();
module Accessibility {
- interface Selection {
+ interface Selection : Bonobo::Unknown {
long getNSelectedChildren ();
Accessible getSelectedChild (in long selectedChildIndex);
boolean selectChild (in long childIndex);
* Boston, MA 02111-1307, USA.
*/
+#include <Bonobo_Storage.idl>
+
module Accessibility {
typedef sequence<string> StringSeq;
SEEK_CURRENT
};
- interface InputStream {
- void open ();
- long read (inout OctetSeq buffer, in long howmany);
- boolean seek (in long offset, in SeekType type);
- boolean rewind ();
- void close ();
- };
-
interface StreamableContent {
StringSeq getContentTypes ();
- InputStream getContent (in string contentType);
+ Bonobo::Stream getContent (in string contentType);
+ /* methods used from Bonobo::Stream : seek, read. Others unsupported. */
};
};
module Accessibility {
- interface Action {
+ interface Action : Bonobo::Unknown {
/**
* getNActions:
module Accessibility {
- interface Component {
+ interface Component : Bonobo::Unknown {
boolean contains (in long x, in long y);
Accessible getAccessibleAtPoint (in long x, in long y);
module Accessibility {
- interface Hyperlink {
+ interface Hyperlink : Bonobo::Unknown {
Accessible getAnchor (in long i);
Accessible getObject (in long i);
long getStartIndex ();
module Accessibility {
- interface Hypertext {
+ interface Hypertext : Text {
long getNLinks ();
Hyperlink getLink (in long linkIndex);
long getLinkIndex (in long characterIndex);
module Accessibility {
- interface Image {
+ interface Image : Bonobo::Unknown {
string getImageDescription ();
long getImageHeight ();
long getImageWidth ();
module Accessibility {
- interface Selection {
+ interface Selection : Bonobo::Unknown {
long getNSelectedChildren ();
Accessible getSelectedChild (in long selectedChildIndex);
boolean selectChild (in long childIndex);
* Boston, MA 02111-1307, USA.
*/
+#include <Bonobo_Storage.idl>
+
module Accessibility {
typedef sequence<string> StringSeq;
SEEK_CURRENT
};
- interface InputStream {
- void open ();
- long read (inout OctetSeq buffer, in long howmany);
- boolean seek (in long offset, in SeekType type);
- boolean rewind ();
- void close ();
- };
-
interface StreamableContent {
StringSeq getContentTypes ();
- InputStream getContent (in string contentType);
+ Bonobo::Stream getContent (in string contentType);
+ /* methods used from Bonobo::Stream : seek, read. Others unsupported. */
};
};
/*
* Our parent Gtk object type
*/
-#define PARENT_TYPE BONOBO_X_OBJECT_TYPE
+#define PARENT_TYPE BONOBO_OBJECT_TYPE
/*
* A pointer to our parent object class
printf("accessible_object_finalize called\n");
g_object_unref (accessible->atko);
+ accessible->atko = NULL;
printf("atko freed, calling parent finalize\n");
accessible_parent_class->finalize (object);
printf ("Accessible set_name called: %s\n", name);
}
+/*
+ * CORBA Accessibility::Accessible::get_description method implementation
+ */
+static CORBA_char *
+impl_accessibility_accessible_get_description (PortableServer_Servant servant,
+ CORBA_Environment *ev)
+{
+ CORBA_char * retval;
+ Accessible *accessible = ACCESSIBLE (bonobo_object_from_servant (servant));
+ retval = CORBA_string_dup (atk_object_get_description (accessible->atko));
+ fprintf (stderr, "Accessible get_description called: %s\n", retval);
+ return retval;
+}
+
+/*
+ * CORBA Accessibility::Accessible::set_description method implementation
+ */
+static void
+impl_accessibility_accessible_set_description (PortableServer_Servant servant,
+ const CORBA_char *name,
+ CORBA_Environment *ev)
+{
+ Accessible *accessible = ACCESSIBLE (bonobo_object_from_servant (servant));
+ atk_object_set_description (accessible->atko, name);
+ printf ("Accessible set_description called: %s\n", name);
+}
+
static void
accessible_class_init (AccessibleClass *klass)
{
GObjectClass * object_class = (GObjectClass *) klass;
POA_Accessibility_Accessible__epv *epv = &klass->epv;
- accessible_parent_class = g_type_class_ref (BONOBO_X_OBJECT_TYPE);
- /*accessible_parent_class = g_type_class_peek_parent (klass);*/
+ accessible_parent_class = g_type_class_peek_parent (klass);
object_class->finalize = accessible_object_finalize;
epv->_get_name = impl_accessibility_accessible_get_name;
epv->_set_name = impl_accessibility_accessible_set_name;
+ epv->_get_description = impl_accessibility_accessible_get_description;
+ epv->_set_description = impl_accessibility_accessible_set_description;
+
+ /* epv->_get_parent = impl_accessibility_accessible_get_parent; */
+ /* epv->_get_childCount = impl_accessibility_accessible_get_child_count; */
+ /* epv->getChildAtIndex = impl_accessibility_accessible_get_child_at_index; */
+ /* epv->getIndexInParent = impl_accessibility_accessible_get_index_in_parent; */
+ /* epv->getRelationSet = impl_accessibility_accessible_get_relation_set; */
+ /* epv->getState = impl_accessibility_accessible_get_state; */
+ /* epv->getRole = impl_accessibility_accessible_get_role; */
}
static void
NULL /* value table */
};
/*
- * Here we use bonobo_x_type_unique instead of
- * gtk_type_unique, this auto-generates a load of
+ * Bonobo_type_unique auto-generates a load of
* CORBA structures for us. All derived types must
- * use bonobo_x_type_unique.
+ * use bonobo_type_unique.
*/
- type = bonobo_x_type_unique (
+ type = bonobo_type_unique (
PARENT_TYPE,
POA_Accessibility_Accessible__init,
NULL,
extern "C" {
#endif /* __cplusplus */
-#include <bonobo/bonobo-xobject.h>
+#include <bonobo/bonobo-object.h>
#include <atk/atkobject.h>
#include <libspi/Accessibility.h>
#define IS_ACCESSIBLE_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), ACCESSIBLE_TYPE))
typedef struct {
- BonoboXObject parent;
+ BonoboObject parent;
AtkObject *atko;
} Accessible;
typedef struct {
- BonoboXObjectClass parent_class;
+ BonoboObjectClass parent_class;
POA_Accessibility_Accessible__epv epv;
} AccessibleClass;
NULL /* value table */
};
/*
- * Here we use bonobo_x_type_unique instead of
- * gtk_type_unique, this auto-generates a load of
+ * Bonobo_type_unique auto-generates a load of
* CORBA structures for us. All derived types must
- * use bonobo_x_type_unique.
+ * use bonobo_type_unique.
*/
- type = bonobo_x_type_unique (
+ type = bonobo_type_unique (
PARENT_TYPE,
POA_Accessibility_Application__init,
NULL,
NULL /* value table */
};
/*
- * Here we use bonobo_x_type_unique instead of
+ * Here we use bonobo_type_unique instead of
* gtk_type_unique, this auto-generates a load of
* CORBA structures for us. All derived types must
- * use bonobo_x_type_unique.
+ * use bonobo_type_unique.
*/
- type = bonobo_x_type_unique (
+ type = bonobo_type_unique (
PARENT_TYPE,
POA_Accessibility_Desktop__init,
NULL,
* CORBA structures for us. All derived types must
* use bonobo_x_type_unique.
*/
- type = bonobo_x_type_unique (
+ type = bonobo_type_unique (
PARENT_TYPE,
POA_Accessibility_Registry__init,
NULL,
NULL /* value table */
};
/*
- * Here we use bonobo_x_type_unique instead of
+ * Here we use bonobo_type_unique instead of
* gtk_type_unique, this auto-generates a load of
* CORBA structures for us. All derived types must
- * use bonobo_x_type_unique.
+ * use bonobo_type_unique.
*/
- type = bonobo_x_type_unique (
+ type = bonobo_type_unique (
PARENT_TYPE,
POA_Accessibility_Desktop__init,
NULL,
* CORBA structures for us. All derived types must
* use bonobo_x_type_unique.
*/
- type = bonobo_x_type_unique (
+ type = bonobo_type_unique (
PARENT_TYPE,
POA_Accessibility_Registry__init,
NULL,