-Makefile.in
-*Makefile
ChangeLog
*.pyc
-aclocal.m4
-autom4te.cache
-config.h.in~
-config
-configure
- GNU LIBRARY GENERAL PUBLIC LICENSE
- Version 2, June 1991
+ GNU LESSER GENERAL PUBLIC LICENSE
+ Version 2.1, February 1999
- Copyright (C) 1991 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ Copyright (C) 1991, 1999 Free Software Foundation, Inc.
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
-[This is the first released version of the library GPL. It is
- numbered 2 because it goes with version 2 of the ordinary GPL.]
+[This is the first released version of the Lesser GPL. It also counts
+ as the successor of the GNU Library Public License, version 2, hence
+ the version number 2.1.]
Preamble
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
- This license, the Library General Public License, applies to some
-specially designated Free Software Foundation software, and to any
-other libraries whose authors decide to use it. You can use it for
-your libraries, too.
-
- When we speak of free software, we are referring to freedom, not
-price. Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-this service if you wish), that you receive source code or can get it
-if you want it, that you can change the software or use pieces of it
-in new free programs; and that you know you can do these things.
+ This license, the Lesser General Public License, applies to some
+specially designated software packages--typically libraries--of the
+Free Software Foundation and other authors who decide to use it. You
+can use it too, but we suggest you first think carefully about whether
+this license or the ordinary General Public License is the better
+strategy to use in any particular case, based on the explanations below.
+
+ When we speak of free software, we are referring to freedom of use,
+not price. Our General Public Licenses are designed to make sure that
+you have the freedom to distribute copies of free software (and charge
+for this service if you wish); that you receive source code or can get
+it if you want it; that you can change the software and use pieces of
+it in new free programs; and that you are informed that you can do
+these things.
To protect your rights, we need to make restrictions that forbid
-anyone to deny you these rights or to ask you to surrender the rights.
-These restrictions translate to certain responsibilities for you if
-you distribute copies of the library, or if you modify it.
+distributors to deny you these rights or to ask you to surrender these
+rights. These restrictions translate to certain responsibilities for
+you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
-code. If you link a program with the library, you must provide
-complete object files to the recipients so that they can relink them
-with the library, after making changes to the library and recompiling
+code. If you link other code with the library, you must provide
+complete object files to the recipients, so that they can relink them
+with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
- Our method of protecting your rights has two steps: (1) copyright
-the library, and (2) offer you this license which gives you legal
+ We protect your rights with a two-step method: (1) we copyright the
+library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
- Also, for each distributor's protection, we want to make certain
-that everyone understands that there is no warranty for this free
-library. If the library is modified by someone else and passed on, we
-want its recipients to know that what they have is not the original
-version, so that any problems introduced by others will not reflect on
-the original authors' reputations.
-
- Finally, any free program is threatened constantly by software
-patents. We wish to avoid the danger that companies distributing free
-software will individually obtain patent licenses, thus in effect
-transforming the program into proprietary software. To prevent this,
-we have made it clear that any patent must be licensed for everyone's
-free use or not licensed at all.
-
- Most GNU software, including some libraries, is covered by the ordinary
-GNU General Public License, which was designed for utility programs. This
-license, the GNU Library General Public License, applies to certain
-designated libraries. This license is quite different from the ordinary
-one; be sure to read it in full, and don't assume that anything in it is
-the same as in the ordinary license.
-
- The reason we have a separate public license for some libraries is that
-they blur the distinction we usually make between modifying or adding to a
-program and simply using it. Linking a program with a library, without
-changing the library, is in some sense simply using the library, and is
-analogous to running a utility program or application program. However, in
-a textual and legal sense, the linked executable is a combined work, a
-derivative of the original library, and the ordinary General Public License
-treats it as such.
-
- Because of this blurred distinction, using the ordinary General
-Public License for libraries did not effectively promote software
-sharing, because most developers did not use the libraries. We
-concluded that weaker conditions might promote sharing better.
-
- However, unrestricted linking of non-free programs would deprive the
-users of those programs of all benefit from the free status of the
-libraries themselves. This Library General Public License is intended to
-permit developers of non-free programs to use free libraries, while
-preserving your freedom as a user of such programs to change the free
-libraries that are incorporated in them. (We have not seen how to achieve
-this as regards changes in header files, but we have achieved it as regards
-changes in the actual functions of the Library.) The hope is that this
-will lead to faster development of free libraries.
+ To protect each distributor, we want to make it very clear that
+there is no warranty for the free library. Also, if the library is
+modified by someone else and passed on, the recipients should know
+that what they have is not the original version, so that the original
+author's reputation will not be affected by problems that might be
+introduced by others.
+\f
+ Finally, software patents pose a constant threat to the existence of
+any free program. We wish to make sure that a company cannot
+effectively restrict the users of a free program by obtaining a
+restrictive license from a patent holder. Therefore, we insist that
+any patent license obtained for a version of the library must be
+consistent with the full freedom of use specified in this license.
+
+ Most GNU software, including some libraries, is covered by the
+ordinary GNU General Public License. This license, the GNU Lesser
+General Public License, applies to certain designated libraries, and
+is quite different from the ordinary General Public License. We use
+this license for certain libraries in order to permit linking those
+libraries into non-free programs.
+
+ When a program is linked with a library, whether statically or using
+a shared library, the combination of the two is legally speaking a
+combined work, a derivative of the original library. The ordinary
+General Public License therefore permits such linking only if the
+entire combination fits its criteria of freedom. The Lesser General
+Public License permits more lax criteria for linking other code with
+the library.
+
+ We call this license the "Lesser" General Public License because it
+does Less to protect the user's freedom than the ordinary General
+Public License. It also provides other free software developers Less
+of an advantage over competing non-free programs. These disadvantages
+are the reason we use the ordinary General Public License for many
+libraries. However, the Lesser license provides advantages in certain
+special circumstances.
+
+ For example, on rare occasions, there may be a special need to
+encourage the widest possible use of a certain library, so that it becomes
+a de-facto standard. To achieve this, non-free programs must be
+allowed to use the library. A more frequent case is that a free
+library does the same job as widely used non-free libraries. In this
+case, there is little to gain by limiting the free library to free
+software only, so we use the Lesser General Public License.
+
+ In other cases, permission to use a particular library in non-free
+programs enables a greater number of people to use a large body of
+free software. For example, permission to use the GNU C Library in
+non-free programs enables many more people to use the whole GNU
+operating system, as well as its variant, the GNU/Linux operating
+system.
+
+ Although the Lesser General Public License is Less protective of the
+users' freedom, it does ensure that the user of a program that is
+linked with the Library has the freedom and the wherewithal to run
+that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
-former contains code derived from the library, while the latter only
-works together with the library.
-
- Note that it is possible for a library to be covered by the ordinary
-General Public License rather than by this special one.
-
- GNU LIBRARY GENERAL PUBLIC LICENSE
+former contains code derived from the library, whereas the latter must
+be combined with the library in order to run.
+\f
+ GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
- 0. This License Agreement applies to any software library which
-contains a notice placed by the copyright holder or other authorized
-party saying it may be distributed under the terms of this Library
-General Public License (also called "this License"). Each licensee is
-addressed as "you".
+ 0. This License Agreement applies to any software library or other
+program which contains a notice placed by the copyright holder or
+other authorized party saying it may be distributed under the terms of
+this Lesser General Public License (also called "this License").
+Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
-
+\f
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
-
- 6. As an exception to the Sections above, you may also compile or
+\f
+ 6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
Library will not necessarily be able to recompile the application
to use the modified definitions.)
- b) Accompany the work with a written offer, valid for at
+ b) Use a suitable shared library mechanism for linking with the
+ Library. A suitable mechanism is one that (1) uses at run time a
+ copy of the library already present on the user's computer system,
+ rather than copying library functions into the executable, and (2)
+ will operate properly with a modified version of the library, if
+ the user installs one, as long as the modified version is
+ interface-compatible with the version that the work was made with.
+
+ c) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
- c) If distribution of the work is made by offering access to copy
+ d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
- d) Verify that the user has already received a copy of these
+ e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
-the source code distributed need not include anything that is normally
-distributed (in either source or binary form) with the major
+the materials to be distributed need not include anything that is
+normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
-
+\f
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties to
+You are not responsible for enforcing compliance by third parties with
this License.
-
+\f
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
-versions of the Library General Public License from time to time.
+versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
-
+\f
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
DAMAGES.
END OF TERMS AND CONDITIONS
-
+\f
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
+ modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
+ version 2.1 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.
+ Lesser 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.
+ You should have received a copy of the GNU Lesser General Public
+ License along with this library; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
+++ /dev/null
-Install procedure
------------------
-
- % gzip -cd at-spi-1.9.0.tar.gz | tar xvf - # unpack the sources
- % cd at-spi-1.9.0 # change to the toplevel directory
- % ./configure # run the `configure' script
- % make # build at-spi
-
- [ Become root if necessary ]
- % make install # install at-spi
-
-Requirements
-------------
-
- GNU make
- GNU autotools
-
- pkg-config
-
- python
-
- glib
- gtk+
- gail
-
- dbus
- dbus-glib
- dbus-python
-
- X
- XEVIE (Reccomended)
-
-Mike Gorse <mgorse@novell.com>
+Mike Gorse <mgorse@suse.com>
+++ /dev/null
-SUBDIRS=droute atk-adaptor
-
-if ATSPI_TESTS
-
-SUBDIRS += tests
-
-endif
-
-gtk_modulesdir = $(libdir)/gnome-settings-daemon-3.0/gtk-modules/
-gtk_modules_DATA = at-spi2-atk.desktop
-
-pkgconfigdir = $(libdir)/pkgconfig
-pkgconfig_DATA = atk-bridge-2.0.pc
-
-EXTRA_DIST = $(gtk_modules_DATA) atk-bridge-2.0.pc.in
-
-What's new in at-spi2-atk 2.20.1:
+What's new in at-spi2-atk 2.34.1:
-* emit_event: Fix out-of-bounds memory access if class is NULL (bgo#758935).
+* socket_embed_hook: Make plug_id parameter const.
-* Remove a debug print.
+What's new in at-spi2-atk 2.34.0:
+
+* Updated doap.
+
+What's new in at-spi2-atk 2.33.92:
+
+* License is now lGPL-2.1+.
+* Several test fixes (thanks to Samuel THibault).
+* Initialize desktop name/path early; needed since we now defer
+ registration.
+
+What's new in at-spi2-atk 2.33.91:
+
+* Defer registration until the main loop is entered. This fixes an issue
+ where a Python application could import gtk but not enter the main loop,
+ resulting in the application registering with AT-SPI but not responding
+ to queries.
+
+* Make sure return values are initialized for some functions.
+
+What's new in at-spi2-atk 2.33.2:
+
+* Add support for ROLE_CONTENT_DELETION and ROLE_CONTENT_INSERTION
+
+* Fix a build issue where libgobject might not have been linked, resulting in
+ undefined symbols.
+
+What's new in at-spi2-atk 2.33.1:
+
+* Document atk_bridge_adaptor_init error messages.
+
+* Add atk_bridge_set_event_context.
+
+* Add AccessibleId property.
+
+What's new in at-spi2-atk 2.31.92:
+
+* Fix a crash when retrieveing headers from table cells.
+
+What's new in at-spi2-atk 2.31.2:
+
+* Add ScrollSubstringTo and ScrollSubstringToPoint interfaces.
+
+What's new in at-spi2-atk 2.29.1:
+
+* Fix a case where we could return without unlocking a mutex (bgo#793625).
+
+* Add ScrollTo and ScrollToPoint interfaces.
+
+* Fix various compiler warnings and build issues.
+
+What's new in at-spi2-atk 2.26.1:
+
+* meson: Ensure paths written to .pc file are absolute.
+
+* Package a couple of missing meson.build files.
+
+What's new in at-spi2-atk 2.25.3:
+
+* Add error-message, error-for, details, and details-for relation types
+
+* Add Meson build system (thanks to Emmanuele Bassi).
+
+What's new in at-spi2-atk 2.25.2:
+
+* Fix use after free when returned objects hold only one ref (bgo#781716).
+
+* Add some missing roles to correspond with atk (description list,
+ description term, description value, and footnote).
+
+What's new in at-spi2-atk 2.25.1:
+
+* Fix position getter for table cells.
+
+* Fix memory corruption when deleting an event from the list of events
+ for which there are registered listeners (bgo#781658).
+
+What's new in at-spi2-atk 2.24.0:
+
+* test: remove atk_table_cell_get_column_index test, as the
+ at-spi2-core function no longer exists (and never worked anyhow).
+
+What's new in at-spi2-atk 2.22.0:
+
+* Remove some inadverrtently-committed debugging code.
+
+What's new in at-spi2-atk 2.21.91:
+What's new in at-spi2-atk 2.21.91:
+
+* atk_bridge_adaptor_init: return -1 if NO_AT_BRIDGE is set (bgo#770574).
+
+What's new in at-spi2-atk 2.21.4:
+
+* emit_event: Fix out-of-bounds memory access if class is NULL.
* Collection: fix missing return value (bgo#758934).
A git repository with the latest development code is available at:
- git://git.gnome.org/at-spi2-atk
+ https://git.gnome.org/browse/at-spi2-atk
Code in this repository depends on at-spi2-core resources. The
at-spi2-core repository can be found at:
- git://git.gnome.org/at-spi2-core
+ https://git.gnome.org/browse/at-spi2-core
More information
----------------
mind that the D-Bus AT-SPI design documents on this page
have not been kept up to date.
- http://live.gnome.org/GAP/AtSpiDbusInvestigation/
+ https://wiki.gnome.org/Accessibility/Documentation/GNOME2/ATSPI2-Investigation
Other sources of relevant information about AT-SPI and Accessibility
include:
- http://live.gnome.org/Accessibility
- http://www.sun.com/software/star/gnome/accessibility/architecture.xml
- http://accessibility.kde.org/developer/atk.php
- http://www.gnome.org/~billh/at-spi-idl/html/
+ https://wiki.gnome.org/Accessibility
+ https://accessibility.kde.org/developer/atk.php
+ https://people.gnome.org/~billh/at-spi-idl/html/
These libraries depend on the at-spi2-core code that contains the daemon for
registering applications, D-Bus helper libraries and the AT-SPI D-Bus specifications.
+Building this package
+---------------------
+
+In order to build at-spi2-atk you will need:
+
+ - Python 3.5
+ - Meson
+ - Ninja
+
+Additionally, you will need the development files for:
+
+ - libdbus
+ - GLib
+ - GTK+ 3.x
+ - ATK
+ - AT-SPI
+
+To build and install this package, you will typically need to run `meson` to
+configure the build process, and Ninja to run the compilation and installation
+instructions:
+
+ # Configure the build and initialize the build directory
+ meson _build .
+
+ # Enter the build directory
+ cd _build
+
+ # Build the project
+ ninja
+
+ # Install the project
+ sudo ninja install
+
Tests
-----
-To run tests execute autogen.sh with '--with-tests=yes' parameter then
-after 'make', type 'make check'.
-Test result is available in tests/atk-test.log
+To run the test suite, use `meson test` from the build directory.
Directory structure
-------------------
<shortdesc xml:lang="en">GTK+ module for bridging AT-SPI to ATK</shortdesc>
<description xml:lang="en">at-spi2-atk is the library used to bridge ATK to AT-SPI, allowing applications exposing information via ATK to interface with clients that use AT-SPI. This module provides the necessary inter-process communication to allow accessibility-oriented software to operate.</description>
<homepage rdf:resource="http://www.linuxfoundation.org/en/Accessibility/ATK/AT-SPI/AT-SPI_on_D-Bus"/>
+ <license rdf:resource="http://usefulinc.com/doap/licenses/lgpl" />
+ <bug-database rdf:resource="https://gitlab.gnome.org/GNOME/at-spi2-atk/issues/" />
+ <download-page rdf:resource="http://download.gnome.org/sources/at-spi2-atk/" />
<mailing-list rdf:resource="https://lists.linux-foundation.org/mailman/listinfo/accessibility-atspi"/>
<category rdf:resource="http://api.gnome.org/doap-extensions#core" />
<programming-language>C</programming-language>
<maintainer>
<foaf:Person>
- <foaf:name>Mark Doffman</foaf:name>
- <foaf:mbox rdf:resource="mailto:mark.doffman@codethink.co.uk" />
- <gnome:userid>markdoffman</gnome:userid>
- </foaf:Person>
- </maintainer>
- <maintainer>
- <foaf:Person>
<foaf:name>Mike Gorse</foaf:name>
<foaf:mbox rdf:resource="mailto:mgorse@suse.com" />
<gnome:userid>mgorse</gnome:userid>
+++ /dev/null
-SUBDIRS= adaptors . gtk-2.0
-
-lib_LTLIBRARIES = libatk-bridge-2.0.la
-
-libatk_bridge_2_0_la_CFLAGS = \
- $(DBUS_CFLAGS) \
- $(ATK_CFLAGS) \
- $(ATSPI_CFLAGS) \
- -I$(top_srcdir) \
- -I$(top_srcdir)/atk-adaptor/adaptors \
- $(P2P_CFLAGS)
-
-atkbridgeincludedir = $(pkgincludedir)/2.0/
-atkbridgeinclude_HEADERS = atk-bridge.h
-
-libatk_bridge_2_0_la_SOURCES = \
- accessible-leasing.c \
- accessible-leasing.h \
- accessible-cache.c \
- accessible-cache.h \
- accessible-register.c \
- accessible-register.h \
- accessible-stateset.c \
- accessible-stateset.h \
- bitarray.h \
- introspection.c \
- introspection.h \
- bridge.c \
- bridge.h \
- object.c \
- object.h \
- event.c \
- event.h \
- spi-dbus.c \
- spi-dbus.h \
- atk-bridge.h
-
-libatk_bridge_2_0_la_LIBADD = \
- $(DBUS_LIBS) \
- $(GMODULE_LIBS) \
- $(ATK_LIBS) \
- $(ATSPI_LIBS) \
- $(top_builddir)/droute/libdroute.la \
- $(top_builddir)/atk-adaptor/adaptors/libatk-bridge-adaptors.la
-
-libatk_bridge_2_0_la_LDFLAGS = \
- $(LT_VERSION_INFO) \
- -export-symbols $(srcdir)/atkbridge.symbols \
- -no-undefined \
- $(AM_LDFLAGS)
-
-EXTRA_DIST = Makefile.include \
- atkbridge.symbols
* Copyright 2009, 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
#include "accessible-cache.h"
#include "accessible-register.h"
#include "bridge.h"
+#include "event.h"
SpiCache *spi_global_cache = NULL;
const gchar *detail = NULL;
- g_rec_mutex_lock (&cache_mutex);
-
/*
* Ensure that only accessibles already in the cache
* have their signals processed.
accessible = ATK_OBJECT (g_value_get_object (¶m_values[0]));
g_return_val_if_fail (ATK_IS_OBJECT (accessible), TRUE);
+ g_rec_mutex_lock (&cache_mutex);
+
if (spi_cache_in (cache, G_OBJECT(accessible)))
{
#ifdef SPI_ATK_DEBUG
g_queue_push_tail (cache->add_traversal, child);
if (cache->add_pending_idle == 0)
- cache->add_pending_idle = g_idle_add (add_pending_items, cache);
+ cache->add_pending_idle = spi_idle_add (add_pending_items, cache);
}
#ifdef SPI_ATK_DEBUG
recursion_check_unset ();
{
SpiCache *cache = spi_global_cache;
- g_rec_mutex_lock (&cache_mutex);
-
g_return_if_fail (ATK_IS_OBJECT (accessible));
+ g_rec_mutex_lock (&cache_mutex);
+
if (spi_cache_in (cache, G_OBJECT(accessible)))
{
#ifdef SPI_ATK_DEBUG
g_queue_push_tail (cache->add_traversal, child);
if (cache->add_pending_idle == 0)
- cache->add_pending_idle = g_idle_add (add_pending_items, cache);
+ cache->add_pending_idle = spi_idle_add (add_pending_items, cache);
#ifdef SPI_ATK_DEBUG
recursion_check_unset ();
#endif
* Copyright 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef ACCESSIBLE_CACHE_H
* Copyright 2009, 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
#include <string.h>
#include "accessible-leasing.h"
+#include "event.h"
#ifdef SPI_ATK_DEBUG
#include "accessible-cache.h"
/* The current time is implicitly rounded down here by ignoring the us */
g_get_current_time (&t);
next_expiry = elem->expiry_s - t.tv_sec;
- leasing->expiry_func_id = g_timeout_add_seconds (next_expiry,
- expiry_func, leasing);
+ leasing->expiry_func_id = spi_timeout_add_seconds (next_expiry,
+ expiry_func, leasing);
}
/*---------------------------------------------------------------------------*/
* Copyright 2008, 2009 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef ACCESSIBLE_LEASING_H
* Copyright 2008, 2009, 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
* Copyright 2008, 2009 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef ACCESSIBLE_REGISTER_H
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
/* stateset.c : implements the StateSet interface */
-#include <config.h>
-#include <stdio.h>
+#include "config.h"
+
#include "accessible-stateset.h"
#include "bitarray.h"
+#include <stdio.h>
+
static AtspiStateType *accessible_state_types = NULL;
static AtkStateType *atk_state_types = NULL;
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
-#ifndef ACCESSSIBLE_STATE_SET_H_
+#ifndef ACCESSIBLE_STATE_SET_H_
#define ACCESSIBLE_STATE_SET_H_
#include <atk/atkstateset.h>
+++ /dev/null
-noinst_LTLIBRARIES = libatk-bridge-adaptors.la
-
-libatk_bridge_adaptors_la_CFLAGS =\
- $(DBUS_CFLAGS) \
- $(ATK_CFLAGS) \
- $(ATSPI_CFLAGS) \
- -I$(top_srcdir) \
- -I$(top_srcdir)/atk-adaptor \
- $(P2P_CFLAGS)
-
-libatk_bridge_adaptors_la_LIBADD =\
- $(DBUS_LIBS) \
- $(ATK_LIBS) \
- $(ATSPI_LIBS)
-
-libatk_bridge_adaptors_la_SOURCES =\
- accessible-adaptor.c \
- action-adaptor.c \
- adaptors.h \
- application-adaptor.c \
- cache-adaptor.c \
- collection-adaptor.c \
- component-adaptor.c \
- document-adaptor.c \
- editabletext-adaptor.c \
- hyperlink-adaptor.c \
- hypertext-adaptor.c \
- image-adaptor.c \
- selection-adaptor.c \
- socket-adaptor.c \
- table-adaptor.c \
- table-cell-adaptor.c \
- text-adaptor.c \
- value-adaptor.c
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
}
child = atk_object_ref_accessible_child (object, i);
reply = spi_object_return_reference (message, child);
- g_object_unref (child);
+ if (child)
+ g_object_unref (child);
return reply;
}
types[ATK_RELATION_DESCRIPTION_FOR] =
ATSPI_RELATION_DESCRIPTION_FOR;
types[ATK_RELATION_DESCRIBED_BY] = ATSPI_RELATION_DESCRIBED_BY;
+ types[ATK_RELATION_DETAILS] = ATSPI_RELATION_DETAILS;
+ types[ATK_RELATION_DETAILS_FOR] = ATSPI_RELATION_DETAILS_FOR;
+ types[ATK_RELATION_ERROR_MESSAGE] = ATSPI_RELATION_ERROR_MESSAGE;
+ types[ATK_RELATION_ERROR_FOR] = ATSPI_RELATION_ERROR_FOR;
types[ATK_RELATION_NODE_PARENT_OF] = ATSPI_RELATION_NODE_PARENT_OF;
return TRUE;
return reply;
}
+static dbus_bool_t
+impl_get_AccessibleId (DBusMessageIter * iter, void *user_data)
+{
+ AtkObject *object = (AtkObject *) user_data;
+
+ g_return_val_if_fail (ATK_IS_OBJECT (user_data), FALSE);
+
+ return droute_return_v_string (iter, atk_object_get_accessible_id (object));
+}
+
static DRouteMethod methods[] = {
{impl_GetChildAtIndex, "GetChildAtIndex"},
{impl_GetChildren, "GetChildren"},
{impl_get_Parent, NULL, "Parent"},
{impl_get_ChildCount, NULL, "ChildCount"},
{impl_get_Attributes, NULL, "Attributes"},
+ {impl_get_AccessibleId, NULL, "AccessibleId"},
{NULL, NULL, NULL}
};
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef ADAPTORS_H
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* Copyright 2008, 2009 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <string.h>
if (!toolkit_name)
toolkit_name = atk_get_toolkit_name ();
+ if (!toolkit_name)
+ return "no toolkit name set yet";
+
/* TODO: query object attributes */
return toolkit_name;
}
* Copyright 2007 IBM Corp.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
/* collection.c: implements the Collection interface */
{
AtkObject *child = atk_object_ref_accessible_child (obj, i);
- g_object_unref (child);
+ if (!child)
+ continue;
+
if (prev && child == pobj)
{
+ g_object_unref (child);
return kount;
}
kount = sort_order_canonical (mrp, ls, kount,
max, child, 0, TRUE,
pobj, recurse, traverse);
+ g_object_unref (child);
}
return kount;
}
and get it's last descendant.
First, get the previous sibling */
nextobj = atk_object_ref_accessible_child (parent, indexinparent - 1);
- g_object_unref (nextobj);
/* Now, drill down the right side to the last descendant */
- while (atk_object_get_n_accessible_children (nextobj) > 0)
+ while (nextobj && atk_object_get_n_accessible_children (nextobj) > 0)
{
- nextobj = atk_object_ref_accessible_child (nextobj,
+ AtkObject *follow;
+
+ follow = atk_object_ref_accessible_child (nextobj,
atk_object_get_n_accessible_children
(nextobj) - 1);
g_object_unref (nextobj);
+ nextobj = follow;
}
/* recurse with the last descendant */
kount = sort_order_rev_canonical (mrp, ls, kount, max,
nextobj, TRUE, pobj);
+ if (nextobj)
+ g_object_unref (nextobj);
}
else if (max == 0 || kount < max)
{
}
}
+#if 0
static void
skip (const char **p)
{
dbus_message_iter_init (message, &iter);
walk (&iter, sig, FALSE);
}
+#endif
static DBusMessage *
impl_GetTree (DBusConnection * bus,
append_accessible_properties (&iter_array, object, properties);
dbus_message_iter_close_container (&iter, &iter_array);
}
-//walkm (reply);
+#if 0
+ walkm (reply);
+#endif
return reply;
}
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
return reply;
}
+static DBusMessage *
+impl_ScrollTo (DBusConnection * bus,
+ DBusMessage * message, void *user_data)
+{
+ AtkComponent *component = (AtkComponent *) user_data;
+ dbus_uint32_t type;
+ dbus_bool_t ret;
+ DBusMessage *reply = NULL;
+
+ g_return_val_if_fail (ATK_IS_COMPONENT (user_data),
+ droute_not_yet_handled_error (message));
+
+ if (!dbus_message_get_args
+ (message, NULL, DBUS_TYPE_UINT32, &type, DBUS_TYPE_INVALID))
+ {
+ return droute_invalid_arguments_error (message);
+ }
+
+ ret = atk_component_scroll_to (component, type);
+
+ reply = dbus_message_new_method_return (message);
+ if (reply)
+ {
+ dbus_message_append_args (reply, DBUS_TYPE_BOOLEAN, &ret,
+ DBUS_TYPE_INVALID);
+ }
+ return reply;
+}
+
+static DBusMessage *
+impl_ScrollToPoint (DBusConnection * bus,
+ DBusMessage * message, void *user_data)
+{
+ AtkComponent *component = (AtkComponent *) user_data;
+ dbus_uint32_t type;
+ dbus_int32_t x, y;
+ dbus_bool_t ret;
+ DBusMessage *reply = NULL;
+
+ g_return_val_if_fail (ATK_IS_COMPONENT (user_data),
+ droute_not_yet_handled_error (message));
+
+ if (!dbus_message_get_args
+ (message, NULL, DBUS_TYPE_UINT32, &type,
+ DBUS_TYPE_INT32, &x,
+ DBUS_TYPE_INT32, &y,
+ DBUS_TYPE_INVALID))
+ {
+ return droute_invalid_arguments_error (message);
+ }
+
+ ret = atk_component_scroll_to_point (component, type, x, y);
+
+ reply = dbus_message_new_method_return (message);
+ if (reply)
+ {
+ dbus_message_append_args (reply, DBUS_TYPE_BOOLEAN, &ret,
+ DBUS_TYPE_INVALID);
+ }
+ return reply;
+}
+
static DRouteMethod methods[] = {
{impl_Contains, "Contains"},
{impl_GetAccessibleAtPoint, "GetAccessibleAtPoint"},
{impl_SetExtents, "SetExtents"},
{impl_SetPosition, "SetPosition"},
{impl_SetSize, "SetSize"},
+ {impl_ScrollTo, "ScrollTo"},
+ {impl_ScrollToPoint, "ScrollToPoint"},
{NULL, NULL}
};
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
--- /dev/null
+source = [
+ 'accessible-adaptor.c',
+ 'action-adaptor.c',
+ 'application-adaptor.c',
+ 'cache-adaptor.c',
+ 'collection-adaptor.c',
+ 'component-adaptor.c',
+ 'document-adaptor.c',
+ 'editabletext-adaptor.c',
+ 'hyperlink-adaptor.c',
+ 'hypertext-adaptor.c',
+ 'image-adaptor.c',
+ 'selection-adaptor.c',
+ 'socket-adaptor.c',
+ 'table-adaptor.c',
+ 'table-cell-adaptor.c',
+ 'text-adaptor.c',
+ 'value-adaptor.c',
+]
+
+libatk_bridge_adaptors = static_library('atk-bridge-adaptors', source,
+ include_directories: [
+ root_inc,
+ include_directories('..'),
+ ],
+ dependencies: [ libdbus_dep, atspi_dep, atk_dep ],
+ c_args: p2p_cflags)
+
+libatk_bridge_adaptors_dep = declare_dependency(link_with: libatk_bridge_adaptors,
+ dependencies: [ libdbus_dep, atspi_dep, atk_dep ],
+ include_directories: include_directories('.'))
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
message, -1, &error);
dbus_message_unref (message);
if (!reply)
- return;
+ {
+ *x = -1;
+ *y = -1;
+ *width = -1;
+ *height = -1;
+ return;
+ }
signature = dbus_message_get_signature (reply);
if (g_strcmp0 (signature, "(iiii)") != 0)
- {
- g_warning ("Got unexpected signature %s from GetExtents\n", signature);
- dbus_message_unref (reply);
- return;
- }
+ {
+ g_warning ("Got unexpected signature %s from GetExtents\n", signature);
+ dbus_message_unref (reply);
+ *x = -1;
+ *y = -1;
+ *width = -1;
+ *height = -1;
+ return;
+ }
dbus_message_iter_init (reply, &iter);
dbus_message_iter_recurse (&iter, &iter_struct);
dbus_message_iter_get_basic (&iter_struct, &tmp);
message, -1, &error);
dbus_message_unref (message);
if (!reply)
- return;
+ {
+ *x = -1;
+ *y = -1;
+ return;
+ }
if (!dbus_message_get_args (reply, NULL, DBUS_TYPE_INT32, &x_dbus,
DBUS_TYPE_INT32, &y_dbus, DBUS_TYPE_INVALID))
{
g_warning ("GetPosition failed: %s", error.message);
dbus_error_free (&error);
+ *x = -1;
+ *y = -1;
}
else
{
message, -1, &error);
dbus_message_unref (message);
if (!reply)
- return;
+ {
+ *width = -1;
+ *height = -1;
+ return;
+ }
if (!dbus_message_get_args (reply, NULL, DBUS_TYPE_INT32, &width_dbus,
DBUS_TYPE_INT32, &height_dbus, DBUS_TYPE_INVALID))
{
g_warning ("GetSize failed: %s", error.message);
dbus_error_free (&error);
+ *width = -1;
+ *height = -1;
}
else
{
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
/* streamablecontent.c : implements the StreamableContent interface */
-#include <config.h>
-#include <stdio.h>
-#include <string.h>
+#include "config.h"
#include <libspi/component.h>
#include <libspi/streamablecontent.h>
+#include <stdio.h>
+#include <string.h>
+
/* Our parent Gtk object type */
#define PARENT_TYPE SPI_TYPE_BASE
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <atk/atk.h>
}
dbus_message_iter_close_container (&iter, &iter_array);
g_ptr_array_unref (array);
- return message;
+ return reply;
}
static DBusMessage *
{
AtkTableCell *cell = (AtkTableCell *) user_data;
gint row = -1, column = -1;
- dbus_int32_t d_row, d_column;
DBusMessageIter iter_struct, iter_variant;
g_return_val_if_fail (ATK_IS_TABLE_CELL (user_data), FALSE);
if (!atk_table_cell_get_position (cell, &row, &column))
return FALSE;
- d_row = row;
- d_column = column;
- dbus_message_iter_open_container (iter, DBUS_TYPE_STRUCT, "(ii)", &iter_variant);
- dbus_message_iter_open_container (&iter_struct, DBUS_TYPE_STRUCT, NULL, &iter_struct);
- dbus_message_iter_append_basic (&iter_struct, DBUS_TYPE_INT32, &row);
- dbus_message_iter_append_basic (&iter_struct, DBUS_TYPE_INT32, &column);
+ dbus_message_iter_open_container (iter, DBUS_TYPE_VARIANT, "(ii)", &iter_variant);
+ dbus_message_iter_open_container (&iter_variant, DBUS_TYPE_STRUCT, NULL, &iter_struct);
+ dbus_message_iter_append_basic (&iter_struct, DBUS_TYPE_INT32, (dbus_int32_t *) &row);
+ dbus_message_iter_append_basic (&iter_struct, DBUS_TYPE_INT32, (dbus_int32_t *) &column);
dbus_message_iter_close_container (&iter_variant, &iter_struct);
dbus_message_iter_close_container (iter, &iter_variant);
return TRUE;
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <string.h>
AtkText *text = (AtkText *) user_data;
dbus_int32_t offset;
char *attributeName;
- dbus_int32_t startOffset, endOffset;
- dbus_bool_t defined;
gint intstart_offset = 0, intend_offset = 0;
char *rv = NULL;
DBusMessage *reply;
set = atk_text_get_run_attributes (text, offset,
&intstart_offset, &intend_offset);
- startOffset = intstart_offset;
- endOffset = intend_offset;
- defined = FALSE;
cur_attr = (GSList *) set;
while (cur_attr)
{
if (!strcmp (at->name, attributeName))
{
rv = at->value;
- defined = TRUE;
break;
}
cur_attr = cur_attr->next;
return reply;
}
+static DBusMessage *
+impl_ScrollSubstringTo (DBusConnection * bus,
+ DBusMessage * message, void *user_data)
+{
+ AtkText *text = (AtkText *) user_data;
+ dbus_int32_t startOffset, endOffset;
+ dbus_uint32_t type;
+ dbus_bool_t ret;
+ DBusMessage *reply = NULL;
+
+ g_return_val_if_fail (ATK_IS_TEXT (user_data),
+ droute_not_yet_handled_error (message));
+
+ if (!dbus_message_get_args
+ (message, NULL, DBUS_TYPE_INT32, &startOffset,
+ DBUS_TYPE_INT32, &endOffset,
+ DBUS_TYPE_UINT32, &type,
+ DBUS_TYPE_INVALID))
+ {
+ return droute_invalid_arguments_error (message);
+ }
+
+ ret = atk_text_scroll_substring_to (text, startOffset, endOffset, type);
+
+ reply = dbus_message_new_method_return (message);
+ if (reply)
+ {
+ dbus_message_append_args (reply, DBUS_TYPE_BOOLEAN, &ret,
+ DBUS_TYPE_INVALID);
+ }
+ return reply;
+}
+
+static DBusMessage *
+impl_ScrollSubstringToPoint (DBusConnection * bus,
+ DBusMessage * message, void *user_data)
+{
+ AtkText *text = (AtkText *) user_data;
+ dbus_int32_t startOffset, endOffset;
+ dbus_uint32_t type;
+ dbus_int32_t x, y;
+ dbus_bool_t ret;
+ DBusMessage *reply = NULL;
+
+ g_return_val_if_fail (ATK_IS_TEXT (user_data),
+ droute_not_yet_handled_error (message));
+
+ if (!dbus_message_get_args
+ (message, NULL, DBUS_TYPE_INT32, &startOffset,
+ DBUS_TYPE_INT32, &endOffset,
+ DBUS_TYPE_UINT32, &type,
+ DBUS_TYPE_INT32, &x,
+ DBUS_TYPE_INT32, &y,
+ DBUS_TYPE_INVALID))
+ {
+ return droute_invalid_arguments_error (message);
+ }
+
+ ret = atk_text_scroll_substring_to_point (text, startOffset, endOffset, type, x, y);
+
+ reply = dbus_message_new_method_return (message);
+ if (reply)
+ {
+ dbus_message_append_args (reply, DBUS_TYPE_BOOLEAN, &ret,
+ DBUS_TYPE_INVALID);
+ }
+ return reply;
+}
+
static DRouteMethod methods[] = {
{impl_GetText, "GetText"},
{impl_SetCaretOffset, "SetCaretOffset"},
{impl_GetBoundedRanges, "GetBoundedRanges"},
{impl_GetAttributeRun, "GetAttributeRun"},
{impl_GetDefaultAttributeSet, "GetDefaultAttributeSet"},
+ {impl_ScrollSubstringTo, "ScrollSubstringTo"},
+ {impl_ScrollSubstringToPoint, "ScrollSubstringToPoint"},
{NULL, NULL}
};
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <math.h>
* Copyright 2008, 2009, 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef ATK_BRIDGE_H
int atk_bridge_adaptor_init (int * argc, char ** argv[]);
void atk_bridge_adaptor_cleanup (void);
+void atk_bridge_set_event_context(GMainContext *cnx);
G_END_DECLS
atk_bridge_adaptor_init
atk_bridge_adaptor_cleanup
+atk_bridge_set_event_context
* Copyright 2008 Novell, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef _BITARRAY_H
* Copyright 2001, 2002, 2003 Ximian, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#define _GNU_SOURCE
get_registered_event_listeners (spi_global_app_data);
}
-static gboolean
-register_application (SpiBridge * app)
+gboolean
+_atk_bridge_register_application (gpointer data)
{
+ SpiBridge * app = data;
DBusMessage *message;
DBusMessageIter iter;
DBusPendingCall *pending;
- g_free (app->desktop_name);
- g_free (app->desktop_path);
-
- /* These will be overridden when we get a reply, but in practice these
- defaults should always be correct */
- app->desktop_name = g_strdup (ATSPI_DBUS_NAME_REGISTRY);
- app->desktop_path = g_strdup (ATSPI_DBUS_PATH_ROOT);
+ spi_global_app_data->registration_pending = 0;
message = dbus_message_new_method_call (SPI_DBUS_NAME_REGISTRY,
ATSPI_DBUS_PATH_ROOT,
if (message)
dbus_message_unref (message);
- return TRUE;
+ return FALSE;
}
/*---------------------------------------------------------------------------*/
DBusMessageIter iter;
const char *uname;
+ if (spi_global_app_data->registration_pending)
+ {
+ g_source_remove (spi_global_app_data->registration_pending);
+ spi_global_app_data->registration_pending = 0;
+ return;
+ }
+
message = dbus_message_new_method_call (SPI_DBUS_NAME_REGISTRY,
ATSPI_DBUS_PATH_REGISTRY,
ATSPI_DBUS_INTERFACE_REGISTRY,
}
static void
-socket_embed_hook (AtkSocket * socket, gchar * plug_id)
+socket_embed_hook (AtkSocket * socket, const gchar * plug_id)
{
g_return_if_fail (spi_global_register != NULL);
{
dbus_connection_set_unix_user_function (con, user_check, NULL, NULL);
dbus_connection_ref(con);
- atspi_dbus_connection_setup_with_g_main(con, NULL);
+ atspi_dbus_connection_setup_with_g_main(con, spi_context);
droute_intercept_dbus (con);
droute_context_register (spi_global_app_data->droute, con);
if (!g_strcmp0 (evdata->bus_name, bus_name) &&
spi_event_is_subtype (evdata->data, remove_data))
{
+ GList *next;
GList *events = spi_global_app_data->events;
+
g_strfreev (evdata->data);
g_free (evdata->bus_name);
g_slist_free_full (evdata->properties, free_property_definition);
g_free (evdata);
- if (list->prev)
- {
- GList *next = list->next;
- list->prev = g_list_remove (list->prev, evdata);
- list = next;
- }
- else
- {
- spi_global_app_data->events = g_list_remove (events, evdata);
- list = spi_global_app_data->events;
- }
+
+ next = list->next;
+ spi_global_app_data->events = g_list_delete_link (events, list);
+ list = next;
}
else
{
{
if (registry_lost && !old[0])
{
- register_application (spi_global_app_data);
+ _atk_bridge_register_application (spi_global_app_data);
registry_lost = FALSE;
}
else if (!new[0])
return -1;
}
- atspi_dbus_server_setup_with_g_main(server, NULL);
+ atspi_dbus_server_setup_with_g_main(server, spi_context);
dbus_server_set_new_connection_function(server, new_connection_cb, NULL, NULL);
spi_global_app_data->server = server;
}
}
-/*
- * spi_app_init
+/**
+ * atk_bridge_adaptor_init: initializes the atk bridge adaptor
*
* The following needs to be initialized.
*
* - setup the bus for p2p communication
* - Application registration with the AT-SPI registry.
*
+ * Returns: 0 if the bridge gets or was already initialized
+ * succesfully, -1 otherwise
*/
int
atk_bridge_adaptor_init (gint * argc, gchar ** argv[])
if (inited && !load_bridge)
g_warning ("ATK Bridge is disabled but a11y has already been enabled.");
- if (inited || !load_bridge)
+ if (inited)
return 0;
+ if (!load_bridge)
+ return -1;
inited = TRUE;
/* Allocate global data and do ATK initializations */
spi_global_app_data = g_new0 (SpiBridge, 1);
spi_global_app_data->root = g_object_ref (root);
+ spi_global_app_data->desktop_name = g_strdup (ATSPI_DBUS_NAME_REGISTRY);
+ spi_global_app_data->desktop_path = g_strdup (ATSPI_DBUS_PATH_ROOT);
/* Set up D-Bus connection and register bus name */
dbus_error_init (&error);
NULL);
/* Register this app by sending a signal out to AT-SPI registry daemon */
- if (!atspi_no_register && (!root || !ATK_IS_PLUG (root)))
- register_application (spi_global_app_data);
+ if (!atspi_no_register && (!root || !ATK_IS_PLUG (root)) &&
+ !spi_global_app_data->registration_pending)
+ spi_global_app_data->registration_pending = spi_idle_add (_atk_bridge_register_application, spi_global_app_data);
else
get_registered_event_listeners (spi_global_app_data);
* Copyright 2008, 2009, 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef BRIDGE_H
GList *events;
gboolean events_initialized;
GHashTable *property_hash;
+ guint registration_pending;
};
extern SpiBridge *spi_global_app_data;
GType *type);
GType _atk_bridge_type_from_iface (const char *iface);
+
+gboolean _atk_bridge_register_application (gpointer data);
G_END_DECLS
#endif /* BRIDGE_H */
* Copyright 2001, 2002, 2003 Ximian, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <string.h>
static gint atk_bridge_key_event_listener_id;
static gint atk_bridge_focus_tracker_id;
+GMainContext *spi_context = NULL;
+
/*---------------------------------------------------------------------------*/
#define ITF_EVENT_OBJECT "org.a11y.atspi.Event.Object"
atspi_set_main_context (cnx);
for (list = spi_global_app_data->direct_connections; list; list = list->next)
atspi_dbus_connection_setup_with_g_main (list->data, cnx);
+
+ if (spi_global_app_data->registration_pending)
+ {
+ g_source_remove (spi_global_app_data->registration_pending);
+ spi_global_app_data->registration_pending = spi_idle_add (_atk_bridge_register_application, spi_global_app_data);
+ }
+}
+
+guint
+spi_idle_add(GSourceFunc function, gpointer data)
+{
+ GSource *source;
+ guint id;
+
+ source = g_idle_source_new ();
+ g_source_set_callback (source, function, data, NULL);
+ id = g_source_attach (source, spi_context);
+ g_source_unref (source);
+
+ return id;
+}
+
+guint
+spi_timeout_add_seconds (gint interval, GSourceFunc function, gpointer data)
+{
+ GSource *source;
+ guint id;
+
+ source = g_timeout_source_new_seconds (interval);
+ g_source_set_callback (source, function, data, NULL);
+ id = g_source_attach (source, spi_context);
+ g_source_unref (source);
+
+ return id;
}
static void
closure->reply = dbus_pending_call_steal_reply (pending);
dbus_pending_call_unref (pending);
- switch_main_context (NULL);
+ switch_main_context (spi_context);
g_main_loop_quit (closure->loop);
}
{
SpiReentrantCallClosure *closure = data;
- switch_main_context (NULL);
+ switch_main_context (spi_context);
g_main_loop_quit (closure->loop);
closure->timeout = -1;
return FALSE;
if (!dbus_connection_send_with_reply (bus, message, &pending, 9000) || !pending)
{
- switch_main_context (NULL);
+ switch_main_context (spi_context);
return NULL;
}
dbus_pending_call_set_notify (pending, set_reply, (void *) &closure, NULL);
return closure.reply;
}
+void
+atk_bridge_set_event_context(GMainContext *cnx)
+{
+ spi_context = cnx;
+ switch_main_context(spi_context);
+}
+
/*---------------------------------------------------------------------------*/
/*
* this instead, so that we don't send these if no one is listening */
if (!g_strcmp0 (data [1], "ChildrenChanged") ||
((!g_strcmp0 (data [1], "PropertyChange")) &&
- (!g_strcmp0 (data [2], "accessible-name") ||
- !g_strcmp0 (data [2], "accessible-description") ||
- !g_strcmp0 (data [2], "accessible-parent") ||
- !g_strcmp0 (data [2], "accessible-role"))) ||
+ (!g_strcmp0 (data [2], "AccessibleName") ||
+ !g_strcmp0 (data [2], "AccessibleDescription") ||
+ !g_strcmp0 (data [2], "AccessibleParent") ||
+ !g_strcmp0 (data [2], "AccessibleRole"))) ||
!g_strcmp0 (data [1], "StateChanged"))
{
if (minor && !g_strcmp0 (minor, "defunct"))
return ret;
}
-static void
-open_variant (DBusMessageIter *iter, const char *name, const char *type,
- DBusMessageIter *out)
-{
- dbus_message_iter_append_basic (iter, DBUS_TYPE_STRING, &name);
- dbus_message_iter_open_container (iter, DBUS_TYPE_VARIANT, type, out);
-}
-
/*
* Emits an AT-SPI event.
* AT-SPI events names are split into three parts:
gchar *cname;
DBusMessage *sig;
- DBusMessageIter iter, iter_dict, iter_dict_entry, iter_variant, iter_array;
+ DBusMessageIter iter, iter_dict, iter_dict_entry;
GArray *properties = NULL;
if (!klass) klass = "";
#define STATE_CHANGED "state-changed"
-static void
-do_debug_thing (AtkObject *accessible)
-{
- AtkObject *parent;
- gint x, y, width, height;
-
- do
- {
- parent = atk_object_get_parent (accessible);
- if (!ATK_IS_COMPONENT (accessible))
- {
- return;
- }
- atk_component_get_extents (ATK_COMPONENT (accessible), &x, &y, &width, &height, ATK_XY_SCREEN);
- accessible = parent;
- } while (accessible);
-}
-
/*
* The state event listener handles 'Gtk:AtkObject:state-change' ATK signals
* and forwards them as object:state-changed:(param-name) AT-SPI events. Where
emit_event (accessible, ITF_EVENT_OBJECT, STATE_CHANGED, pname, detail1, 0,
DBUS_TYPE_INT32_AS_STRING, 0, append_basic);
-if (!g_strcmp0 (pname, "focused") && detail1 && g_getenv("DODEBUG")) do_debug_thing(accessible);
if (!g_strcmp0 (pname, "defunct") && detail1)
spi_register_deregister_object (spi_global_register, G_OBJECT (accessible),
TRUE);
if (G_VALUE_TYPE (¶m_values[3]) == G_TYPE_STRING)
text = g_value_get_string (¶m_values[3]);
+ else
+ text = "";
emit_event (accessible, ITF_EVENT_OBJECT, name, minor, detail1, detail2,
DBUS_TYPE_STRING_AS_STRING, text, append_basic);
if (G_VALUE_TYPE (¶m_values[3]) == G_TYPE_STRING)
text = g_value_get_string (¶m_values[3]);
+ else
+ text = "";
emit_event (accessible, ITF_EVENT_OBJECT, name, minor, detail1, detail2,
DBUS_TYPE_STRING_AS_STRING, text, append_basic);
* Copyright 2008, 2009 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef EVENT_H
void spi_atk_tidy_windows (void);
gboolean spi_event_is_subtype (gchar **needle, gchar **haystack);
+
+extern GMainContext *spi_context;
+guint spi_idle_add(GSourceFunc function, gpointer data);
+guint spi_timeout_add_seconds (gint interval, GSourceFunc function, gpointer data);
#endif /* EVENT_H */
+++ /dev/null
- gtkmoduledir = $(libdir)/gtk-2.0/modules
-
-include $(top_srcdir)/atk-adaptor/Makefile.include
-
-libatk_bridge_la_SOURCES = module.c
* Copyright 2001, 2002, 2003 Ximian, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#define _GNU_SOURCE
" <arg direction=\"out\" type=\"b\" />"
" </method>"
""
+" <method name=\"ScrollTo\">"
+" <arg direction=\"in\" name=\"type\" type=\"u\"/>"
+" </method>"
+""
+" <method name=\"ScrollToPoint\">"
+" <arg direction=\"in\" name=\"type\" type=\"u\"/>"
+" <arg direction=\"in\" name=\"x\" type=\"i\"/>"
+" <arg direction=\"in\" name=\"y\" type=\"i\"/>"
+" </method>"
+""
"</interface>"
"";
" <arg direction=\"out\" type=\"a{ss}\" />"
" </method>"
""
+" <method name=\"ScrollSubstringTo\">"
+" <arg direction=\"in\" name=\"startOffset\" type=\"i\" />"
+" <arg direction=\"in\" name=\"endOffset\" type=\"i\" />"
+" <arg direction=\"in\" name=\"type\" type=\"u\"/>"
+" </method>"
+""
+" <method name=\"ScrollSubstringToPoint\">"
+" <arg direction=\"in\" name=\"startOffset\" type=\"i\" />"
+" <arg direction=\"in\" name=\"endOffset\" type=\"i\" />"
+" <arg direction=\"in\" name=\"type\" type=\"u\"/>"
+" <arg direction=\"in\" name=\"x\" type=\"i\"/>"
+" <arg direction=\"in\" name=\"y\" type=\"i\"/>"
+" </method>"
+""
"</interface>"
"";
--- /dev/null
+subdir('adaptors')
+
+atk_bridge_sources = [
+ 'accessible-leasing.c',
+ 'accessible-cache.c',
+ 'accessible-register.c',
+ 'accessible-stateset.c',
+ 'introspection.c',
+ 'bridge.c',
+ 'object.c',
+ 'event.c',
+ 'spi-dbus.c',
+]
+
+install_headers([ 'atk-bridge.h' ], subdir: join_paths(meson.project_name(), '2.0'))
+
+libatk_bridge = shared_library('atk-bridge-2.0', atk_bridge_sources,
+ include_directories: root_inc,
+ dependencies: [
+ libatk_bridge_adaptors_dep,
+ libdroute_dep,
+ libdbus_dep,
+ gmodule_dep,
+ gobject_dep,
+ atk_dep,
+ atspi_dep,
+ ],
+ c_args: p2p_cflags,
+ version: atk_bridge_libversion,
+ soversion: atk_bridge_soversion,
+ install: true)
+
+libatk_bridge_dep = declare_dependency(link_with: libatk_bridge,
+ include_directories: [
+ root_inc,
+ include_directories('.')
+ ])
+
+atk_bridge_module = shared_module('atk-bridge', 'gtk-2.0/module.c',
+ include_directories: root_inc,
+ dependencies: [
+ libatk_bridge_dep,
+ libdbus_dep,
+ atk_dep,
+ atspi_dep,
+ gmodule_dep,
+ ],
+ c_args: p2p_cflags,
+ install: true,
+ install_dir: join_paths(get_option('libdir'), 'gtk-2.0', 'modules'))
+
+pkgconfig = import('pkgconfig')
+pkgconfig.generate(
+ name: 'atk-bridge-2.0',
+ description: 'ATK/D-Bus Bridge',
+ version: meson.project_version(),
+ libraries: libatk_bridge,
+ requires_private: ['gobject-2.0', 'atspi-2'],
+ filebase: 'atk-bridge-2.0',
+ subdirs: 'at-spi2-atk/2.0',
+ install_dir: join_paths(get_option('libdir'), 'pkgconfig'),
+)
* Copyright 2008, 2009, 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
/*
role_table[ATK_ROLE_MATH_ROOT] = ATSPI_ROLE_MATH_ROOT;
role_table[ATK_ROLE_SUBSCRIPT] = ATSPI_ROLE_SUBSCRIPT;
role_table[ATK_ROLE_SUPERSCRIPT] = ATSPI_ROLE_SUPERSCRIPT;
+ role_table[ATK_ROLE_DESCRIPTION_LIST] = ATSPI_ROLE_DESCRIPTION_LIST;
+ role_table[ATK_ROLE_DESCRIPTION_TERM] = ATSPI_ROLE_DESCRIPTION_TERM;
+ role_table[ATK_ROLE_DESCRIPTION_VALUE] = ATSPI_ROLE_DESCRIPTION_VALUE;
+ role_table[ATK_ROLE_FOOTNOTE] = ATSPI_ROLE_FOOTNOTE;
+ role_table[ATK_ROLE_CONTENT_DELETION] = ATSPI_ROLE_CONTENT_DELETION;
+ role_table[ATK_ROLE_CONTENT_INSERTION] = ATSPI_ROLE_CONTENT_INSERTION;
return TRUE;
}
* Copyright 2008, 2009, 2010 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef ACCESSIBLE_OBJECT_H
* Copyright 2008 Novell, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
* 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
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef SPI_DBUS_H_
+++ /dev/null
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: atk-bridge-2.0
-Description: ATK/D-Bus Bridge
-Version: @VERSION@
-Requires.private: gobject-2.0 atspi-2
-Libs: -L${libdir} -latk-bridge-2.0
-Cflags: -I${includedir}/at-spi2-atk/2.0
+++ /dev/null
-#!/bin/sh
-
-test -n "$srcdir" || srcdir=`dirname "$0"`
-test -n "$srcdir" || srcdir=.
-
-olddir=`pwd`
-cd "$srcdir"
-
-# gnome-autogen.sh runs configure, so do likewise.
-autoreconf -vif
-
-cd "$olddir"
-
-test -n "$NOCONFIGURE" || "$srcdir/configure" "$@"
-
+++ /dev/null
-AC_INIT([at-spi2-atk], [2.20.1], [accessibility-atspi@lists.linux-foundation.org])
-AC_CONFIG_AUX_DIR(config)
-
-AT_SPI_ATK_MAJOR_VERSION=0
-AT_SPI_ATK_MINOR_VERSION=3
-AT_SPI_ATK_INTERFACE_AGE=0
-AT_SPI_ATK_BINARY_AGE=0
-AT_SPI_ATK_VERSION="$AT_SPI_MAJOR_VERSION.$AT_SPI_MINOR_VERSION"
-AC_SUBST(AT_SPI_ATK_VERSION)
-
-# libtool versioning
-LT_RELEASE=$AT_SPI_MAJOR_VERSION.$AT_SPI_MINOR_VERSION
-LT_CURRENT=0
-LT_REVISION=0
-LT_AGE=0
-LT_VERSION_INFO='-version-info ${LT_CURRENT}:${LT_REVISION}:${LT_AGE}'
-AC_SUBST(LT_VERSION_INFO)
-AC_SUBST(LT_RELEASE)
-AC_SUBST(LT_CURRENT)
-AC_SUBST(LT_REVISION)
-AC_SUBST(LT_AGE)
-
-AM_INIT_AUTOMAKE([-Wall foreign no-dist-gzip dist-xz])
-
-# Enable silent build when available (Automake 1.11)
-m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
-
-AC_PROG_CC
-AM_DISABLE_STATIC
-AM_PROG_LIBTOOL
-PKG_PROG_PKG_CONFIG
-
-GETTEXT_PACKAGE="${PACKAGE}"
-AC_SUBST(GETTEXT_PACKAGE)
-
-AC_CONFIG_HEADERS([config.h])
-
-PKG_CHECK_MODULES(DBUS, [dbus-1 >= 1.5])
-AC_SUBST(DBUS_LIBS)
-AC_SUBST(DBUS_CFLAGS)
-
-PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.32.0])
-AC_SUBST(GLIB_LIBS)
-AC_SUBST(GLIB_CFLAGS)
-
-PKG_CHECK_MODULES(GOBJ, [gobject-2.0 >= 2.0.0])
-AC_SUBST(GOBJ_LIBS)
-AC_SUBST(GOBJ_CFLAGS)
-
-PKG_CHECK_MODULES(GMODULE, [gmodule-2.0 >= 2.0.0])
-AC_SUBST(GMODULE_LIBS)
-AC_SUBST(GMODULE_CFLAGS)
-
-PKG_CHECK_MODULES(ATK, [atk >= 2.15.4])
-AC_SUBST(ATK_LIBS)
-AC_SUBST(ATK_CFLAGS)
-
-PKG_CHECK_MODULES(ATSPI, [atspi-2 >= 2.17.90])
-AC_SUBST(ATSPI_LIBS)
-AC_SUBST(ATSPI_CFLAGS)
-
-AC_ARG_WITH([tests],
- [AC_HELP_STRING([--with-tests=yes|no],
- [choose if test should be enabled.
- @<:@default=no@:>@])],
- [build_tests=${withval}],
- [build_tests=no])
-
-want_tests="no"
-
-case "${build_tests}" in
- yes)
- want_tests="yes"
- ;;
- no*)
- ;;
- *)
- AC_MSG_ERROR([Unknown build tests option: --with-tests=${build_tests}])
- ;;
-esac
-
-
-if test "${want_tests}" = "yes"; then
- PKG_CHECK_MODULES(XML, [libxml-2.0 >= 2.9.1])
- AC_SUBST(XML_LIBS)
- AC_SUBST(XML_CFLAGS)
-fi
-AM_CONDITIONAL([ATSPI_TESTS], [test "${want_tests}" = "yes"])
-
-GLIB_GSETTINGS
-
-AC_ARG_ENABLE(p2p, [ --enable-p2p Allow peer-to-peer DBus connections [default=yes]], enable_p2p="$enableval", enable_p2p=yes)
-
-#libtool option to strip symbols starting with cspi
-LIBTOOL_EXPORT_OPTIONS='-export-symbols-regex "^[[^cspi]].*"'
-AC_SUBST(LIBTOOL_EXPORT_OPTIONS)
-
-# Extra libraries for sockets added by Willie Walker
-# based upon how SunStudio libraries work.
-#
-if test "$GCC" = yes; then
- EXTRA_SOCKET_LIBS=""
-else
- EXTRA_SOCKET_LIBS="-lsocket -lnsl"
-fi
-AC_SUBST(EXTRA_SOCKET_LIBS)
-
-dnl find sizes & alignments
-orig_CPPFLAGS=$CPPFLAGS
-CPPFLAGS="$CPPFLAGS $DBUS_CFLAGS"
-CPPFLAGS=$orig_CPPFLAGS
-
-if test "x$GCC" = xyes; then
- CFLAGS="$CFLAGS -Werror-implicit-function-declaration"
-fi
-
-if test "x$enable_p2p" = "xno"; then
- P2P_CFLAGS=-DDISABLE_P2P
-fi
-
-AC_SUBST(P2P_CFLAGS)
-
-AC_CONFIG_FILES([Makefile
- atk-bridge-2.0.pc
- droute/Makefile
- atk-adaptor/Makefile
- atk-adaptor/adaptors/Makefile
- atk-adaptor/gtk-2.0/Makefile
- tests/Makefile
- tests/data/Makefile
- tests/dummyatk/Makefile
- ])
-
-
-AC_OUTPUT
+++ /dev/null
-noinst_LTLIBRARIES = libdroute.la
-
-libdroute_la_CFLAGS = $(DBUS_CFLAGS) \
- $(GLIB_CFLAGS) \
- -I$(top_builddir)\
- -I$(top_srcdir)
-
-libdroute_la_SOURCES =\
- droute.c\
- droute.h\
- droute-variant.c\
- droute-variant.h\
- droute-pairhash.c\
- droute-pairhash.h
-libdroute_la_LIBADD = $(DBUS_LIBS)
-
-TESTS = droute-test
-
-check_PROGRAMS = droute-test
-droute_test_SOURCES = droute-test.c
-droute_test_CFLAGS = $(DBUS_CFLAGS) \
- -I$(top_builddir)\
- $(GLIB_CFLAGS) \
- $(ATSPI_CFLAGS) \
- -I$(top_srcdir)
-
-droute_test_LDFLAGS = libdroute.la\
- $(DBUS_LIBS) \
- $(GLIB_LIBS) \
- $(ATSPI_LIBS)
* Copyright 2008 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "droute-pairhash.h"
* Copyright 2008 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef _DROUTE_PAIRHASH_H
#define _DROUTE_PAIRHASH_H
/* --------------------------------------------------------*/
-out:
g_main_loop_quit (main_loop);
return FALSE;
}
* Copyright 2008 Novell, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdlib.h>
* Copyright 2008 Novell, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef _DROUTE_VARIANT_H
#define _DROUTE_VARIANT_H
* Copyright 2008 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdlib.h>
DBusMessage *ret;
ret = dbus_message_new_error (message, DBUS_ERROR_FAILED, error.message);
dbus_error_free (&error);
+ return ret;
}
_DROUTE_DEBUG ("DRoute (handle prop): %s|%s on %s\n", pair.one, pair.two, pathstr);
* Copyright 2008 Codethink Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef _DROUTE_H
#define _DROUTE_H
--- /dev/null
+droute_sources = [
+ 'droute.c',
+ 'droute-variant.c',
+ 'droute-pairhash.c',
+]
+
+libdroute = static_library('droute', droute_sources,
+ dependencies: [ glib_dep, libdbus_dep ],
+ include_directories: root_inc)
+
+libdroute_dep = declare_dependency(link_with: libdroute,
+ dependencies: [ glib_dep, libdbus_dep ],
+ include_directories: include_directories('.'))
+
+droute_test = executable('droute-test', 'droute-test.c',
+ dependencies: [ libdroute_dep, atspi_dep ],
+ include_directories: root_inc)
+test('droute-test', droute_test)
--- /dev/null
+project('at-spi2-atk', 'c',
+ version: '2.34.1',
+ license: 'LGPLv2.1+',
+ default_options: [
+ 'buildtype=debugoptimized',
+ 'warning_level=1',
+ 'c_std=c99',
+ ],
+ meson_version : '>= 0.40.1')
+
+atk_bridge_soversion = 0
+atk_bridge_libversion = '0.0.0'
+
+cc = meson.get_compiler('c')
+host_system = host_machine.system()
+
+# XXX: for strcasecmp(); should use g_ascii_strcasecmp()
+add_project_arguments([ '-D_DEFAULT_SOURCE', ], language: 'c')
+
+# We are using deprecated API; don't warn if we're building stable
+# releases, to avoid making the build logs less readable. We keep
+# the warnings during development cycles, to remind us we should
+# port away from deprecated API
+if meson.project_version().split('.').get(1).to_int().is_even()
+ add_project_arguments([ '-DATK_DISABLE_DEPRECATION_WARNINGS' ], language: 'c')
+endif
+
+# XXX: Unused
+at_spi_conf = configuration_data()
+at_spi_conf.set('GETTEXT_PACKAGE', meson.project_name())
+configure_file(output: 'config.h',
+ configuration: at_spi_conf)
+
+root_inc = include_directories('.')
+
+# Dependencies
+libdbus_req_version = '>= 1.5'
+glib_req_version = '>= 2.32.0'
+gobject_req_version = '>= 2.0.0'
+gmodule_req_version = '>= 2.0.0'
+atk_req_version = '>= 2.33.3'
+atspi_req_version = '>= 2.33.2'
+libxml_req_version = '>= 2.9.1'
+
+libdbus_dep = dependency('dbus-1', version: libdbus_req_version)
+glib_dep = dependency('glib-2.0', version: glib_req_version)
+gobject_dep = dependency('gobject-2.0', version: gobject_req_version)
+gmodule_dep = dependency('gmodule-2.0', version: gmodule_req_version)
+atk_dep = dependency('atk', version: atk_req_version)
+atspi_dep = dependency('atspi-2', version: atspi_req_version)
+libxml_dep = dependency('libxml-2.0', version: libxml_req_version, required: false)
+
+if get_option('disable_p2p')
+ p2p_cflags = [ '-DDISABLE_P2P' ]
+else
+ p2p_cflags = []
+endif
+
+install_data('at-spi2-atk.desktop',
+ install_dir: join_paths(get_option('libdir'), 'gnome-settings-daemon-3.0', 'gtk-modules'))
+
+subdir('droute')
+subdir('atk-adaptor')
+subdir('tests')
--- /dev/null
+option('disable_p2p',
+ description: 'Disable peer-to-peer DBus connections',
+ type: 'boolean',
+ value: false)
+++ /dev/null
-SUBDIRS = data dummyatk
-
-noinst_PROGRAMS = atk-test app-test
-TESTS = atk-test
-lib_LTLIBRARIES =libxmlloader.la libtestutils.la
-
-atk_test_CFLAGS = $(DBUS_CFLAGS) \
- $(GLIB_CFLAGS) \
- $(ATSPI_CFLAGS) \
- -I$(top_builddir)\
- -I$(top_srcdir)/tests/dummyatk/ \
- -I$(top_builddir)/tests/dummyatk/.libs \
- -I$(top_builddir)/tests/dummyatk/.deps \
- -I$(top_srcdir) \
- -Wall
-
-atk_test_LDADD = libxmlloader.la \
- libtestutils.la \
- $(GLIB_LIBS) \
- $(ATSPI_LIBS) \
- $(top_builddir)/tests/dummyatk/libdummyatk.la
-
-atk_test_CPPFLAGS = -DTESTS_BUILD_DIR=\"$(top_builddir)/tests\" \
- -DTESTS_SRC_DIR=\"$(top_srcdir)/tests\" \
- -DTESTS_DATA_DIR=\"$(top_srcdir)/tests/data\"
-
-atk_test_SOURCES = atk_suite.c \
- atk_suite.h \
- atk_test_accessible.c \
- atk_test_action.c \
- atk_test_component.c \
- atk_test_collection.c \
- atk_test_editable_text.c \
- atk_test_document.c \
- atk_test_hyperlink.c \
- atk_test_hypertext.c \
- atk_test_image.c \
- atk_test_selection.c \
- atk_test_state_set.c \
- atk_test_table.c \
- atk_test_table_cell.c \
- atk_test_text.c \
- atk_test_value.c
-
-app_test_CFLAGS = -I$(top_builddir) \
- $(GLIB_CFLAGS) \
- $(ATK_CFLAGS) \
- -I$(top_srcdir)/tests/dummyatk \
- -I$(top_srcdir)/atk-adaptor \
- -Wall
-
-app_test_LDADD = libxmlloader.la \
- libtestutils.la \
- $(GLIB_LIBS) \
- $(ATK_LIBS) \
- $(top_builddir)/tests/dummyatk/libdummyatk.la \
- $(top_builddir)/atk-adaptor/libatk-bridge-2.0.la
-
-app_test_SOURCES = test-application.c
-
-libxmlloader_la_CFLAGS = $(GLIB_CFLAGS) \
- $(GOBJ_CFLAGS) \
- $(XML_CFLAGS) \
- $(ATK_CFLAGS) \
- -I$(top_srcdir)/tests/dummyatk/ \
- -Wall
-
-libxmlloader_la_LIBADD = $(GLIB_LIBS) \
- $(XML_LIBS) \
- $(GOBJ_LIBS) \
- $(top_builddir)/tests/dummyatk/libdummyatk.la \
- $(ATK_LIBS)
-
-libxmlloader_la_SOURCES = atk-object-xml-loader.c\
- atk-object-xml-loader.h
-
-libtestutils_la_CFLAGS = -I$(top_builddir) \
- $(GLIB_CFLAGS) \
- $(ATSPI_CFLAGS) \
- -Wall
-
-libtestutils_la_LIBADD = $(GLIB_LIBS) \
- $(ATSPI_LIBS)
-
-libtestutils_la_SOURCES = atk_test_util.c \
- atk_test_util.h
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdlib.h>
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef ATK_OBJECT_XML_LOADER_H
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdlib.h>
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef _ATK_SUITE_H
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_accessible_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
void
atk_test_accessible (void)
{
- g_test_add_vtable (ATK_TEST_PATH_ACCESSIBLE "/atk_test_accesible_get_name",
+ g_test_add_vtable (ATK_TEST_PATH_ACCESSIBLE "/atk_test_accessible_get_name",
0, NULL, NULL, atk_test_accessible_get_name, teardown_accessible_test);
g_test_add_vtable (ATK_TEST_PATH_ACCESSIBLE "/atk_test_accessible_get_description",
0, NULL, NULL, atk_test_accessible_get_description, teardown_accessible_test);
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_action_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
static void
teardown_collection_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_component_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_document_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_editable_text_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_test_util.h"
static void
teardown_hyperlink_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_test_util.h"
static void
teardown_hypertext_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_image_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_selection_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_suite.h"
static void
teardown_state_set_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
static void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_test_util.h"
static void
teardown_table_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_test_util.h"
*/
static void
-atk_test_table_cell_get_column_index (gpointer fixture, gconstpointer user_data)
-{
- AtspiAccessible *_obj = get_root_obj (DATA_FILE);
- g_assert (_obj);
- AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL);
- g_assert (child);
-
- AtspiAccessible *cell = atspi_accessible_get_child_at_index (child, 10, NULL);
- AtspiTableCell *obj = atspi_accessible_get_table_cell (cell);
- g_assert (obj);
-
- /* ATK Table Cell interface do not implement that func */
- g_assert_cmpint (-1, ==, atspi_table_cell_get_column_index (obj, NULL));
-}
-
-static void
atk_test_table_cell_get_row_span (gpointer fixture, gconstpointer user_data)
{
AtspiAccessible *_obj = get_root_obj (DATA_FILE);
}
static void
+atk_test_table_cell_get_position (gpointer fixture, gconstpointer user_data)
+{
+ AtspiAccessible *_obj = get_root_obj (DATA_FILE);
+ g_assert (_obj);
+ AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL);
+ g_assert (child);
+
+ AtspiAccessible *cell = atspi_accessible_get_child_at_index (child, 9, NULL);
+ AtspiTableCell *obj = atspi_accessible_get_table_cell (cell);
+ g_assert (cell);
+
+ gint row = 10;
+ gint column = 10;
+
+ atspi_table_cell_get_position (obj, &row, &column, NULL);
+
+ /* TODO: not a very good test for the app to return (-1, -1) */
+ g_assert_cmpint (row, ==, -1);
+ g_assert_cmpint (column, ==, -1);
+}
+
+static void
atk_test_table_cell_get_table (gpointer fixture, gconstpointer user_data)
{
AtspiAccessible *_obj = get_root_obj (DATA_FILE);
static void
teardown_table_cell_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
void
g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_column_header_cells",
0, NULL, NULL, atk_test_table_cell_get_column_header_cells, teardown_table_cell_test);
*/
- g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_column_index",
- 0, NULL, NULL, atk_test_table_cell_get_column_index, teardown_table_cell_test);
g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_row_span",
0, NULL, NULL, atk_test_table_cell_get_row_span, teardown_table_cell_test);
/*
*/
g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_row_column_span",
0, NULL, NULL, atk_test_table_cell_get_row_column_span, teardown_table_cell_test);
+ g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_position",
+ 0, NULL, NULL, atk_test_table_cell_get_position, teardown_table_cell_test);
g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_table",
0, NULL, NULL, atk_test_table_cell_get_table, teardown_table_cell_test);
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_test_util.h"
static void
teardown_text_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
void
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <signal.h>
#include "atk_test_util.h"
+pid_t child_pid;
+
static void assert_clean_exit (int sig)
{
kill (child_pid, SIGTERM);
{
child_pid = fork ();
if (child_pid == 0) {
- execlp ("./app-test",
- "./app-test",
+ execlp (TESTS_BUILD_DIR "/app-test",
+ TESTS_BUILD_DIR "/app-test",
"--test-data-file",
file_name,
NULL);
_exit (EXIT_SUCCESS);
}
+ if (child_pid) fprintf(stderr, "child_pid %d\n", child_pid);
}
-AtspiAccessible * get_root_obj (const char *file_name)
+static AtspiAccessible *try_get_root_obj (AtspiAccessible *obj)
{
int i;
- AtspiAccessible *obj = NULL;
-
- run_app (file_name);
-
- /* sleep is needed to wait for fored test application*/
- sleep (1);
- obj = atspi_get_desktop (0);
gint child_count = atspi_accessible_get_child_count (obj, NULL);
if (child_count < 1) {
- g_test_message ("Fail, test application not found\n");
- g_test_fail ();
- kill (child_pid, SIGTERM);
return NULL;
}
for (i=0; i<child_count; i++) {
AtspiAccessible *child = atspi_accessible_get_child_at_index (obj,i, NULL);
- if (!strcmp (atspi_accessible_get_name (child, NULL), "root_object"))
+ if (child && !strcmp (atspi_accessible_get_name (child, NULL), "root_object"))
return child;
}
- g_test_message ("test object not found\n");
- g_test_fail ();
+ return NULL;
+}
+
+AtspiAccessible * get_root_obj (const char *file_name)
+{
+ int tries = 0;
+ AtspiAccessible *child;
+ struct timespec timeout = { .tv_sec = 0, .tv_nsec = 10 * 1000000 };
+ AtspiAccessible *obj = NULL;
+
+ fprintf(stderr, "run_app: %s\n", file_name);
+ run_app (file_name);
+
+ obj = atspi_get_desktop (0);
+
+ /* Wait for application to start, up to 100 times 10ms. */
+ while (++tries <= 100)
+ {
+ child = try_get_root_obj (obj);
+ if (child)
+ return child;
+
+ nanosleep(&timeout, NULL);
+ }
+
+ if (atspi_accessible_get_child_count (obj, NULL) < 1) {
+ g_test_message ("Fail, test application not found\n");
+ } else {
+ g_test_message ("test object not found\n");
+ }
+ g_test_fail ();
kill (child_pid, SIGTERM);
return NULL;
}
+
+void terminate_app (void)
+{
+ int tries = 0;
+
+ AtspiAccessible *child;
+ struct timespec timeout = { .tv_sec = 0, .tv_nsec = 10 * 1000000 };
+ AtspiAccessible *obj = NULL;
+
+ kill (child_pid, SIGTERM);
+
+ obj = atspi_get_desktop (0);
+
+ /* Wait for application to stop, up to 100 times 10ms. */
+ while (++tries <= 100)
+ {
+ child = try_get_root_obj (obj);
+ if (child == NULL)
+ return;
+
+ nanosleep(&timeout, NULL);
+ }
+
+ g_test_message ("Fail, test application still running\n");
+ g_test_fail ();
+}
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <locale.h>
#include "atk_suite.h"
-pid_t child_pid;
+extern pid_t child_pid;
void run_app (const char *file_name);
AtspiAccessible *get_root_obj (const char *file_name);
+void terminate_app (void);
void clean_exit_on_fail ();
#endif /* _ATK_TEST_UTIL_H */
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include "atk_test_util.h"
g_assert (child);
AtspiValue *obj = atspi_accessible_get_value_iface (child);
gdouble val = atspi_value_get_minimum_value (obj, NULL);
- g_assert_cmpfloat (val, ==, 1.1);
+ g_assert_cmpfloat (val, ==, 1.25);
}
static void
g_assert (child);
AtspiValue *obj = atspi_accessible_get_value_iface (child);
gdouble val = atspi_value_get_current_value (obj, NULL);
- g_assert_cmpfloat (val, ==, 2.1);
+ g_assert_cmpfloat (val, ==, 2.25);
}
static void
g_assert (child);
AtspiValue *obj = atspi_accessible_get_value_iface (child);
gdouble val = atspi_value_get_maximum_value (obj, NULL);
- g_assert_cmpfloat (val, ==, 3.1);
+ g_assert_cmpfloat (val, ==, 3.25);
}
static void
g_assert (child);
AtspiValue *obj = atspi_accessible_get_value_iface (child);
gdouble val = atspi_value_get_minimum_increment (obj, NULL);
- g_assert_cmpfloat (val, ==, 0.1);
+ g_assert_cmpfloat (val, ==, 0.25);
}
static void
teardown_value_test (gpointer fixture, gconstpointer user_data)
{
- kill (child_pid, SIGTERM);
+ terminate_app ();
}
void
+++ /dev/null
-EXTRA_DIST = test-accessible.xml \
- test-action.xml \
- test-component.xml \
- test.xml
<?xml version="1.0" ?>
<accessible description="Root of the accessible tree" name="root_object" role="accelerator label">
<accessible_value description="first child" name="obj0" role="alert">
- <value_node min="1.1" current="2.1" max="3.1" step="0.1"/>
+ <value_node min="1.25" current="2.25" max="3.25" step="0.25"/>
</accessible_value>
</accessible>
+++ /dev/null
-lib_LTLIBRARIES = libdummyatk.la
-
-libdummyatk_la_CFLAGS = $(ATK_CFLAGS) \
- $(GLIB_CFLAGS) \
- $(GOBJ_CFLAGS) \
- -I$(top_srcdir) \
- -Wall
-
-libdummyatk_la_LDFLAGS = -no-undefined
-
-libdummyatk_la_LIBADD = $(ATK_LIBS) \
- $(GLIB_LIBS) \
- $(GOBJ_LIBS)
-
-libdummyatk_la_SOURCES = \
- my-atk-action.c \
- my-atk-action.h \
- my-atk-component.c \
- my-atk-component.h \
- my-atk-document.c \
- my-atk-document.h \
- my-atk-editable-text.c \
- my-atk-editable-text.h \
- my-atk-hyperlink.c \
- my-atk-hyperlink.h \
- my-atk-hypertext.c \
- my-atk-hypertext.h \
- my-atk-image.c \
- my-atk-image.h \
- my-atk-text.c \
- my-atk-text.h \
- my-atk-object.c \
- my-atk-object.h \
- my-atk-table.c \
- my-atk-table.h \
- my-atk-table-cell.c \
- my-atk-table-cell.h \
- my-atk-selection.c \
- my-atk-selection.h \
- my-atk-value.c \
- my-atk-value.h \
- my-atk.h
--- /dev/null
+dummyatk_sources = [
+ 'my-atk-action.c',
+ 'my-atk-component.c',
+ 'my-atk-document.c',
+ 'my-atk-editable-text.c',
+ 'my-atk-hyperlink.c',
+ 'my-atk-hypertext.c',
+ 'my-atk-image.c',
+ 'my-atk-text.c',
+ 'my-atk-object.c',
+ 'my-atk-table.c',
+ 'my-atk-table-cell.c',
+ 'my-atk-selection.c',
+ 'my-atk-value.c',
+]
+
+dummyatk = static_library('dummyatk', dummyatk_sources,
+ include_directories: root_inc,
+ dependencies: [ glib_dep, gobject_dep, atk_dep ])
+
+dummyatk_dep = declare_dependency(link_with: dummyatk,
+ dependencies: [ glib_dep, gobject_dep, atk_dep ],
+ include_directories: include_directories('.'))
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
static gboolean
my_atk_action_do_action (AtkAction *action, gint i)
{
- g_return_val_if_fail (MY_IS_ATK_ACTION (action), NULL);
+ g_return_val_if_fail (MY_IS_ATK_ACTION (action), FALSE);
perform_action (ATK_OBJECT (action));
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_ACTION_H
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <glib-object.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_DOCUMENT_H
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_EDITABLE_TEXT_H_
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <glib.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_HYPERLINK_H_
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <glib.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_HYPERTEXT_H_
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_IMAGE_H_
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
MyAtkObject *obj = MY_ATK_OBJECT (accessible);
if (obj->relation_set == NULL)
obj->relation_set = atk_relation_set_new ();
- return g_object_ref (G_OBJECT (obj->relation_set));
+ return g_object_ref (ATK_RELATION_SET (obj->relation_set));
}
static AtkStateSet *my_atk_object_ref_state_set (AtkObject *accessible)
MyAtkObject *obj = MY_ATK_OBJECT (accessible);
if (obj->state_set == NULL)
obj->state_set = atk_state_set_new ();
- return g_object_ref (G_OBJECT (obj->state_set));
+ return g_object_ref (ATK_STATE_SET (obj->state_set));
}
static AtkAttributeSet *my_atk_object_get_attributes (AtkObject *accessible)
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_SELECTION_H
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <glib.h>
*row = self->xy[0];
*column = self->xy[1];
- return FALSE;
+ return TRUE;
}
static GPtrArray *
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_TABLE_CELL_H_
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <glib.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_TABLE_H_
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <stdio.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_TEXT_H_
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#include <glib.h>
* Copyright (c) 2015 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_VALUE_H_
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef MY_ATK_H
--- /dev/null
+subdir('dummyatk')
+
+xmlloader = static_library('xmlloader', [ 'atk-object-xml-loader.c' ],
+ dependencies: [ glib_dep, gobject_dep, libxml_dep, atk_dep, dummyatk_dep ],
+ include_directories: [ root_inc, include_directories('.') ])
+xmlloader_dep = declare_dependency(link_with: xmlloader)
+
+testutils = static_library('testutils', [ 'atk_test_util.c' ],
+ dependencies: [ glib_dep, atspi_dep ],
+ include_directories: [ root_inc, include_directories('.') ],
+ c_args: ['-DTESTS_BUILD_DIR="@0@"'.format(meson.current_build_dir()) ] )
+testutils_dep = declare_dependency(link_with: testutils)
+
+# tests:
+# - name
+# - sources
+# - dependencies
+tests = [
+ [
+ 'atk-test', [
+ 'atk_suite.c',
+ 'atk_test_accessible.c',
+ 'atk_test_action.c',
+ 'atk_test_component.c',
+ 'atk_test_collection.c',
+ 'atk_test_document.c',
+ 'atk_test_editable_text.c',
+ 'atk_test_hyperlink.c',
+ 'atk_test_hypertext.c',
+ 'atk_test_image.c',
+ 'atk_test_selection.c',
+ 'atk_test_state_set.c',
+ 'atk_test_table.c',
+ 'atk_test_table_cell.c',
+ 'atk_test_text.c',
+ 'atk_test_value.c',
+ ],
+ [
+ glib_dep,
+ atspi_dep,
+ xmlloader_dep,
+ testutils_dep,
+ dummyatk_dep,
+ ]
+ ],
+
+ [
+ 'app-test',
+ [
+ 'test-application.c',
+ ],
+ [
+ glib_dep,
+ atk_dep,
+ xmlloader_dep,
+ testutils_dep,
+ dummyatk_dep,
+ libatk_bridge_dep,
+ ]
+ ],
+]
+
+foreach t: tests
+ test_name = t[0]
+ test_sources = t[1]
+ test_deps = t[2]
+
+ test_bin = executable(test_name, test_sources,
+ dependencies: test_deps,
+ include_directories: root_inc,
+ c_args: [
+ '-DTESTS_BUILD_DIR="@0@"'.format(meson.current_build_dir()),
+ '-DTESTS_SRC_DIR="@0@"'.format(meson.current_source_dir()),
+ '-DTESTS_DATA_DIR="@0@"'.format(join_paths(meson.current_source_dir(), 'data')),
+ ])
+
+ if test_name == 'atk-test'
+ atk_test_bin = test_bin
+ endif
+endforeach
+
+test('atk-test', atk_test_bin, timeout: 120)
* Copyright (c) 2014 Samsung Electronics Co., Ltd.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
+ * modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 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.
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Library General Public
+ * You should have received a copy of the GNU Lesser 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.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
/*