3 #include "../cspi-lowlevel.h"
6 cspi_dup_ref (CORBA_Object object)
8 bonobo_object_dup_ref (object, NULL);
12 cspi_release_unref (CORBA_Object object)
14 bonobo_object_release_unref (object, NULL);
18 cspi_check_ev (const char *error_string)
20 CORBA_Environment *ev = cspi_ev ();
22 if (ev->_major != CORBA_NO_EXCEPTION)
26 err = bonobo_exception_get_text (ev);
28 fprintf (stderr, "Warning: AT-SPI error: %s: %s\n",
33 CORBA_exception_free (ev);
44 cspi_exception_get_text (void)
48 txt = bonobo_exception_get_text (cspi_ev ());
59 CORBA_Object registry;
62 if (!bonobo_init (0, NULL))
64 g_error ("Could not initialize Bonobo");
67 obj_id = "OAFIID:Accessibility_Registry:proto0.1";
69 CORBA_exception_init (&ev);
71 registry = bonobo_activation_activate_from_id (
72 obj_id, 0, NULL, &ev);
74 if (ev._major != CORBA_NO_EXCEPTION)
76 g_error ("AT-SPI error: during registry activation: %s\n",
77 bonobo_exception_get_text (&ev));
80 if (registry == CORBA_OBJECT_NIL)
82 g_error ("Could not locate registry");