+/*
+ * AT-SPI - Assistive Technology Service Provider Interface
+ * (Gnome Accessibility Project; http://developer.gnome.org/projects/gap)
+ *
+ * Copyright 2001, 2002 Sun Microsystems Inc.,
+ * Copyright 2001, 2002 Ximian, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
#include <cspi/spi-private.h>
/**
void
AccessibleHyperlink_unref (AccessibleHyperlink *obj)
{
- cspi_object_ref (obj);
+ cspi_object_unref (obj);
}
/**
long
AccessibleHyperlink_getNAnchors (AccessibleHyperlink *obj)
{
- long retval;
+ dbus_int16_t retval;
cspi_return_val_if_fail (obj != NULL, -1);
- retval =
- Accessibility_Hyperlink__get_nAnchors (CSPI_OBJREF (obj), cspi_ev ());
+ cspi_dbus_get_property (obj, spi_interface_hyperlink, "nAnchors", NULL, "n", &retval);
cspi_return_val_if_ev ("getNAnchors", -1);
AccessibleHyperlink_getURI (AccessibleHyperlink *obj,
long int i)
{
+ dbus_int32_t d_i = i;
char *retval;
cspi_return_val_if_fail (obj != NULL, NULL);
- retval =
- Accessibility_Hyperlink_getURI (CSPI_OBJREF (obj),
- (CORBA_long) i, cspi_ev ());
+ cspi_dbus_call (obj, spi_interface_hyperlink, "getURI", NULL, "i=>s", d_i, &retval);
cspi_return_val_if_ev ("getURI", NULL);
AccessibleHyperlink_getObject (AccessibleHyperlink *obj,
long int i)
{
+ dbus_int32_t d_i = i;
+ char *path;
+ Accessible *retval;
+
cspi_return_val_if_fail (obj != NULL, NULL);
- return cspi_object_add (
- Accessibility_Hyperlink_getObject (CSPI_OBJREF (obj),
- (CORBA_long) i, cspi_ev ()));
+ cspi_dbus_call (obj, spi_interface_hyperlink, "getObject", NULL, "i=>o", d_i, &path);
+ retval = cspi_ref_related_accessible (obj, path);
+ g_free (path);
}
/**
long int *startIndex,
long int *endIndex)
{
- long retval;
+ dbus_int32_t si, ei;
cspi_return_if_fail (obj != NULL);
- *startIndex = (long)
- Accessibility_Hyperlink__get_startIndex (CSPI_OBJREF (obj), cspi_ev ());
- *endIndex = (long)
- Accessibility_Hyperlink__get_endIndex (CSPI_OBJREF (obj), cspi_ev ());
-
- cspi_return_if_ev ("getIndexRange");
+ cspi_dbus_get_property (obj, spi_interface_hyperlink, "startIndex", NULL, "i", &si);
+ cspi_return_if_ev ("startIndex");
+ cspi_dbus_get_property (obj, spi_interface_hyperlink, "endIndex", NULL, "i", &ei);
+ cspi_return_if_ev ("endIndex");
+ *startIndex = si;
+ *endIndex = ei;
}
/**
SPIBoolean
AccessibleHyperlink_isValid (AccessibleHyperlink *obj)
{
- SPIBoolean retval;
+ dbus_bool_t retval;
cspi_return_val_if_fail (obj != NULL, FALSE);
- retval =
- Accessibility_Hyperlink_isValid (CSPI_OBJREF (obj), cspi_ev ());
+ cspi_dbus_call (obj, spi_interface_hyperlink, "isValid", NULL, "=>b", &retval);
cspi_return_val_if_ev ("isValid", FALSE);