from state import *
from streamablecontent import *
from table import *
-from test import *
from text import *
from utils import *
from value import *
from interfaces import ATSPI_ACCESSIBLE, ATSPI_APPLICATION
from base import BaseProxy, Enum
-from factory import create_accessible, add_accessible_class
+from factory import accessible_factory
from state import StateSet, _marshal_state_set
from relation import _marshal_relation_set
from role import Role
Get the containing Application for this object.
@return the Application instance to which this object belongs.
"""
- application_root = self._cache[self._app_name]._get_root()
- #TODO Set the desktop object as the parent of this.
- return create_accessible(self._cache,
- self._app_name,
- application_root,
- ATSPI_APPLICATION,
- connection=self._cache._connection)
+ return self._cache.create_application(self._app_name)
def getAttributes(self):
"""
"""
func = self.get_dbus_method("getAttributes", dbus_interface=ATSPI_ACCESSIBLE)
return func()
-
+
def getChildAtIndex(self, index):
"""
Get the accessible child of this object at index.
@return : the 'nth' Accessible child of this object.
"""
path = self.cached_data.children[index]
- return create_accessible(self._cache,
- self._app_name,
- path,
- ATSPI_ACCESSIBLE,
- connection=self._cache._connection)
+ return self._cache.create_accessible(self._app_name, path, ATSPI_ACCESSIBLE)
def getIndexInParent(self):
"""
name = property(fget=get_name, doc=_nameDoc)
def get_parent(self):
- if self._parent:
- return self._parent
- else:
- return create_accessible(self._cache,
- self._app_name,
- self.cached_data.parent,
- ATSPI_ACCESSIBLE,
- connection=self._cache._connection)
+ return self._cache.create_accessible(self._app_name,
+ self.cached_data.parent,
+ ATSPI_ACCESSIBLE)
_parentDoc = \
"""
"""
parent = property(fget=get_parent, doc=_parentDoc)
-# Register the Accessible class with the accessible factory.
-add_accessible_class(ATSPI_ACCESSIBLE, Accessible)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(ATSPI_ACCESSIBLE, Accessible)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import create_accessible, add_accessible_class
+from factory import accessible_factory
__all__ = [
"Action",
"""
nActions = property(fget=get_nActions, fset=set_nActions, doc=_nActionsDoc)
-# Register the Accessible class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_ACTION, Action)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_ACTION, Action)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
from accessible import Accessible
__all__ = [
"""
version = property(fget=get_version, fset=set_version, doc=_versionDoc)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_APPLICATION, Application)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_APPLICATION, Application)
#END----------------------------------------------------------------------------
--- /dev/null
+#Copyright (C) 2008 Codethink Ltd
+
+#This library is free software; you can redistribute it and/or
+#modify it under the terms of the GNU Lesser General Public
+#License version 2 as published by the Free Software Foundation.
+
+#This program 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 General Public License for more details.
+#You should have received a copy of the GNU Lesser General Public License
+#along with this program; if not, write to the Free Software
+#Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+from accessiblecache import AccessibleCache
+from desktop import Desktop
+from factory import accessible_factory
+
+import interfaces
+
+__all__ = [
+
+ "TestApplicationCache",
+ ]
+
+#------------------------------------------------------------------------------
+
+class TestApplicationCache(object):
+ """
+ Test application store, accesses a single application.
+
+ The store object acts as a central class for creating accessible objects.
+ It interfaces with the ATSPI registry to keep account of all accessible
+ applications. It contains the accessible cache objects from each application.
+
+ @registry: Each accessible cache object must have a reference to the registry
+ object to send update events.
+
+ @connection: D-Bus connection used to access applications.
+
+ @bus_name: The test store only accesses one accessible application, this is its
+ D-Bus path.
+ """
+
+ def __init__(self, registry, connection, bus_name):
+ self._connection = connection
+
+ self.application_list = [bus_name]
+ self.application_cache = {bus_name:AccessibleCache(registry, connection, bus_name)}
+
+ def get_cache_data(self, app_name, acc_path):
+ """
+ Returns the cache tuple for the given application and accessible
+ object path. Throws an IndexError if the cache data is not found.
+ """
+ return self.application_cache[app_name][acc_path]
+
+ def create_application(self, app_name):
+ """
+ Creates an accessible object for the root of the application
+ available at the given D-Bus name.
+ """
+ cls = accessible_factory.get_accessible_class(interfaces.ATSPI_APPLICATION)
+ return cls(app_name, self.application_cache[app_name].root, self, interfaces.ATSPI_APPLICATION)
+
+ def create_accessible(self, app_name, acc_path, interface, dbus_object=None):
+ """
+ Creates an accessible object.
+
+ @app_name: D-Bus name of the application where the accessible object resides.
+
+ @acc_path: D-Bus path of the object within the application.
+
+ @interface: D-Bus interface of the requested object. A different accessible object
+ class will be created depending on this. Making the function much like
+ an accessible object factory.
+
+ @dbus_object: If a D-Bus object already exists for the accessible object it can be
+ provided here so that another one is not created.
+ """
+ # An acc_path of '/' implies the desktop object, whatever the app_name.
+ if acc_path == '/':
+ return Desktop(self)
+ else:
+ cls = accessible_factory.get_accessible_class(interface)
+ return cls(app_name, acc_path, self, interface, dbus_object=dbus_object)
+
+ @property
+ def connection(self):
+ """
+ D-Bus connection used by the store.
+ """
+ return self._connection
+
+#END----------------------------------------------------------------------------
from dbus.exceptions import *
import interfaces
-from factory import create_accessible
__all__ = [
"AccessibleObjectNoLongerExists",
#------------------------------------------------------------------------------
-class BaseProxy(Interface):
+class BaseProxy(object):
"""
The base D-Bus proxy for a remote object that implements one or more
of the AT-SPI interfaces.
__metaclass__ = BaseProxyMeta
- def __init__(self, cache, app_name, acc_path, interface, dbus_object=None, connection=None, parent=None):
+ def __init__(self, app_name, acc_path, cache, interface, dbus_object=None):
"""
Create a D-Bus Proxy for an ATSPI interface.
app_name - D-Bus bus name of the application this accessible belongs to.
acc_path - D-Bus object path of the server side accessible object.
parent - Parent accessible.
- interface - D-Bus interface of the object. Used to decide which accessible class to instanciate.
dbus_object(kwarg) - The D-Bus proxy object used by the accessible for D-Bus method calls.
"""
self._cache = cache
self._app_name = app_name
self._acc_path = acc_path
- self._parent = parent
+ self._dbus_interface = interface
if not dbus_object:
- dbus_object = connection.get_object(self._app_name, self._acc_path, introspect=False)
+ dbus_object = cache.connection.get_object(self._app_name,
+ self._acc_path,
+ introspect=False)
self._dbus_object = dbus_object
- Interface.__init__(self, self._dbus_object, interface)
-
- self._pgetter = self.get_dbus_method("Get", dbus_interface="org.freedesktop.DBus.Properties")
- self._psetter = self.get_dbus_method("Set", dbus_interface="org.freedesktop.DBus.Properties")
-
- def __getattr__(self, attr):
- raise AttributeError("\'%s\' has no attribute \'%s\'" % (self.__class__.__name__, attr))
+ self._pgetter = self.get_dbus_method("Get",
+ dbus_interface="org.freedesktop.DBus.Properties")
+ self._psetter = self.get_dbus_method("Set",
+ dbus_interface="org.freedesktop.DBus.Properties")
def __str__(self):
try:
except Exception:
return '[DEAD]'
+ def __eq__(self, other):
+ if self._app_name == other._app_name and \
+ self._acc_path == other._app_path:
+ return True
+ else:
+ return False
+
+ def __ne__(self, other):
+ return not self.__eq__(other)
+
def get_dbus_method(self, *args, **kwargs):
- method = Interface.get_dbus_method(self, *args, **kwargs)
+ method = self._dbus_object.get_dbus_method(*args, **kwargs)
- def dbus_method_func(*args, **kwargs):
+ def dbus_method_func(*iargs, **ikwargs):
# TODO Need to throw an AccessibleObjectNoLongerExists exception
# on D-Bus error of the same type.
try:
- return method(*args, **kwargs)
+ return method(*iargs, **ikwargs)
except UnknownMethodException, e:
raise NotImplementedError(e)
except DBusException, e:
@property
def cached_data(self):
try:
- return self._cache[self._app_name][self._acc_path]
+ return self._cache.get_cache_data(self._app_name, self._acc_path)
except KeyError:
raise AccessibleObjectNoLongerExists, \
'Cache data cannot be found for path %s in app %s' % (self._acc_path, self._app_name)
is not supported.
"""
if interface in self.interfaces:
- return create_accessible(self._cache,
- self._app_name,
- self._acc_path,
- interface,
- dbus_object=self._dbus_object)
+ return self._cache.create_accessible(self._app_name,
+ self._acc_path,
+ interface,
+ dbus_object=self._dbus_object)
else:
raise NotImplementedError(
"%s not supported by accessible object at path %s"
import interfaces
from base import BaseProxy, Enum
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Collection",
TREE_RESTRICT_CHILDREN = TreeTraversalType(0)
TREE_RESTRICT_SIBLING = TreeTraversalType(1)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_COLLECTION, Collection)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_COLLECTION, Collection)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy, Enum
-from factory import create_accessible, add_accessible_class
+from factory import accessible_factory
from accessible import BoundingBox
from dbus.types import Int16
@return the Accessible child whose bounding box contains the
specified point.
"""
+ #TODO this needs a real implementation
func = self.get_dbus_method("getAccessibleAtPoint")
return func(*args, **kwargs)
func = self.get_dbus_method("registerFocusHandler")
return func(*args, **kwargs)
-# Register the Accessible class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_COMPONENT, Component)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_COMPONENT, Component)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxyMeta
from accessible import BoundingBox
-from cache import AccessibleCache
from state import StateSet
+
from role import ROLE_UNKNOWN
from component import LAYER_WIDGET
#------------------------------------------------------------------------------
-class ApplicationCache(object):
-
- def __init__(self, connection, bus_name):
- self._connection = connection
- self._bus_name = bus_name
- self._accessible_cache = AccessibleCache(connection, bus_name)
-
- def __getitem__(self, key):
- return self._accessible_cache
-
- def __contains__(self, key):
- if key == self._bus_name:
- return True
- else:
- return False
-
- def get_application_at_index(self, index):
- pass
-
- def get_application_count(self):
- return 1
-
-#------------------------------------------------------------------------------
-
class DesktopComponent(object):
"""
The Component interface is implemented by objects which occupy
If the application name is provided the Desktop is being used for
test and will only report the application provided as its single child.
"""
- self._cache = cache
- self._app_name = '/'
+ self._appcache = cache
+ self._app_name = ':'
+ self._acc_path = '/'
def __nonzero__(self):
return True
return self.getChildCount()
def __getitem__(self, index):
+ # IndexError thrown by getChildAtIndex
return self.getChildAtIndex(index)
+ def __eq__(self, other):
+ if self._app_name == other._app_name and \
+ self._acc_path == other._app_path:
+ return True
+ else:
+ return False
+
+ def __ne__(self, other):
+ return not self.__eq__(other)
+
def getApplication(self):
"""
Get the containing Application for this object.
an in parameter indicating which child is requested (zero-indexed).
@return : the 'nth' Accessible child of this object.
"""
- return self._cache.get_application_at_index(index, self)
+ return self._appcache.create_application(self._appcache.application_list[index])
def getIndexInParent(self):
"""
@return : a boolean indicating whether the two object references
point to the same object.
"""
+ #TODO Fix this method
return self == accessible
def get_childCount(self):
- return self._cache.get_application_count()
+ return len(self._appcache.application_list)
_childCountDoc = \
"""
childCount: the number of children contained by this object.
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Document",
func = self.get_dbus_method("getLocale")
return func(*args, **kwargs)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_DOCUMENT, Document)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_DOCUMENT, Document)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
from text import *
__all__ = [
func = self.get_dbus_method("setTextContents")
return func(*args, **kwargs)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_EDITABLE_TEXT, EditableText)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_EDITABLE_TEXT, EditableText)
#END----------------------------------------------------------------------------
#Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
import interfaces
-from factory import create_accessible, add_accessible_class
from accessible import BoundingBox
__all__ = [
@property
def host_application(self):
if not self._application:
- application_root = self._cache[self._source_application]._get_root()
- return create_accessible(self._cache,
- self._source_application,
- application_root,
- interfaces.ATSPI_APPLICATION,
- connection=self._cache._connection)
+ return self._cache.create_application(self._source_application)
return self._application
@property
def source(self):
if not self._source:
- self._source = create_accessible(self._cache,
- self._source_application,
- self._source_path,
- interfaces.ATSPI_ACCESSIBLE,
- connection=self._cache._connection)
+ self._source = self._cache.create_accessible(self._source_application,
+ self._source_path,
+ interfaces.ATSPI_ACCESSIBLE)
return self._source
@property
class AccessibleFactory(object):
__accessible_interfaces = {}
- def create_accessible(self, cache, app_name, acc_path, interface, dbus_object=None, connection=None, parent=None):
- class_ = self.__accessible_interfaces[interface]
- return class_(cache,
- app_name,
- acc_path,
- interface,
- dbus_object=dbus_object,
- connection=connection,
- parent=parent)
-
- def add_accessible_class(self, name, cls):
+ def register_accessible_class(self, name, cls):
self.__accessible_interfaces[name] = cls
-_factory = AccessibleFactory()
-
-def create_accessible(cache, app_name, acc_path, interface, dbus_object=None, connection=None, parent=None):
- """
- Used to create different python classes for each of the accessible interfaces.
-
- The decision on which class to create is based on the name of the
- accessible interface.
-
- cache - ApplicationCache, where the cached data for the accessible can be obtained.
- app_name - D-Bus bus name of the application this accessible belongs to.
- acc_path - D-Bus object path of the server side accessible object.
- interface - D-Bus interface of the object. Used to decide which accessible class to instanciate.
- dbus_object(kwarg) - The D-Bus proxy object used by the accessible for D-Bus method calls.
- connection(kwarg) - Client side D-Bus connection, provided if no D-Bus proxy is available.
- """
- return _factory.create_accessible(cache,
- app_name,
- acc_path,
- interface,
- dbus_object=dbus_object,
- connection=connection,
- parent=parent)
-
-def add_accessible_class(name, cls):
- _factory.add_accessible_class(name, cls)
+ def get_accessible_class(self, name):
+ return self.__accessible_interfaces[name]
+
+accessible_factory = AccessibleFactory()
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Hyperlink",
"""
startIndex = property(fget=get_startIndex, fset=set_startIndex, doc=_startIndexDoc)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_HYPERLINK, Hyperlink)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_HYPERLINK, Hyperlink)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Hypertext",
func = self.get_dbus_method("getNLinks")
return func(*args, **kwargs)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_HYPERTEXT, Hypertext)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_HYPERTEXT, Hypertext)
#END----------------------------------------------------------------------------
import dbus
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
from accessible import BoundingBox
__all__ = [
"""
imageLocale = property(fget=get_imageLocale, fset=set_imageLocale, doc=_imageLocaleDoc)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_IMAGE, Image)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_IMAGE, Image)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy, Enum
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"LoginHelper",
self[0] = val
winID = property(fget=_get_winID, fset=_set_winID)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_LOGIN_HELPER, LoginHelper)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_LOGIN_HELPER, LoginHelper)
#END----------------------------------------------------------------------------
from desktop import Desktop as _Desktop
from event import EventType as _EventType
from event import event_type_to_signal_reciever as _event_type_to_signal_reciever
-from test import TestApplicationCache as _TestApplicationCache
+from applicationcache import TestApplicationCache
from dbus.mainloop.glib import DBusGMainLoop as _DBusGMainLoop
_DBusGMainLoop(set_as_default=True)
app_name = _os.environ["ATSPI_TEST_APP_NAME"]
if app_name:
self._app_name = app_name
- self._cache = _TestApplicationCache(self, self._bus, app_name)
+ self._appcache = TestApplicationCache(self, self._bus, app_name)
self._event_listeners = {}
@return: Desktop reference
@rtype: Accessibility.Desktop
"""
- return _Desktop(self._cache)
+ return _Desktop(self._appcache)
def _callClients(self, register, event):
for client in register.keys():
for name in names:
new_type = _EventType(name)
registered.append((new_type.name,
- _event_type_to_signal_reciever(self._bus, self._cache, client, new_type)))
+ _event_type_to_signal_reciever(self._bus, self._appcache, client, new_type)))
self._registerFake(self._name_type, self._name_listeners, client, *names)
self._registerFake(self._description_type, self._description_listeners, client, *names)
import interfaces
from base import Enum as _Enum
-from factory import create_accessible
#------------------------------------------------------------------------------
e.g. the Object at index i in the list of Objects having the
specified relationship to this Accessible.
"""
- return create_accessible(self._cache,
- self._app_name,
- self._objects[index],
- interfaces.ATSPI_ACCESSIBLE,
- connection=self._cache._connection)
+ return self._cache.create_accessible(self._app_name,
+ self._objects[index],
+ interfaces.ATSPI_ACCESSIBLE)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Selection",
"""
nSelectedChildren = property(fget=get_nSelectedChildren, fset=set_nSelectedChildren, doc=_nSelectedChildrenDoc)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_SELECTION, Selection)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_SELECTION, Selection)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy, Enum
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Selector",
COMMAND_RESULT_OBSOLETE = CommandResult(3)
COMMAND_RESULT_SUCCESS = CommandResult(1)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_SELECTOR, Selector)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_SELECTOR, Selector)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy, Enum
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"ContentStream",
func = self.get_dbus_method("getURI")
return func(*args, **kwargs)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_STREAMABLE_CONTENT, StreamableContent)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_STREAMABLE_CONTENT, StreamableContent)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Table",
"""
summary = property(fget=get_summary, fset=set_summary, doc=_summaryDoc)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_TABLE, Table)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_TABLE, Table)
#END----------------------------------------------------------------------------
+++ /dev/null
-#Copyright (C) 2008 Codethink Ltd
-
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU Lesser General Public
-#License version 2 as published by the Free Software Foundation.
-
-#This program 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 General Public License for more details.
-#You should have received a copy of the GNU Lesser General Public License
-#along with this program; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-from cache import AccessibleCache
-from factory import create_accessible
-
-import interfaces
-
-__all__ = [
- "TestApplicationCache",
- ]
-
-#------------------------------------------------------------------------------
-
-class TestApplicationCache(object):
- """
- Test application cache. Accesses single AccessibleCache.
- """
-
- def __init__(self, registry, connection, bus_name):
- self._connection = connection
- self._bus_name = bus_name
- self._accessible_cache = AccessibleCache(registry, connection, bus_name)
-
- def __getitem__(self, key):
- return self._accessible_cache
-
- def __contains__(self, key):
- if key == self._bus_name:
- return True
- else:
- return False
-
- def get_application_at_index(self, index, parent):
- return create_accessible(self,
- self._bus_name,
- self._accessible_cache.root,
- interfaces.ATSPI_ACCESSIBLE,
- connection=self._connection,
- parent=parent)
-
- def get_application_count(self):
- return 1
-
-#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy, Enum
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Text",
self[3] = val
data = property(fget=_get_data, fset=_set_data)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_TEXT, Text)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_TEXT, Text)
#END----------------------------------------------------------------------------
import interfaces
from base import BaseProxy
-from factory import add_accessible_class
+from factory import accessible_factory
__all__ = [
"Value",
"""
minimumValue = property(fget=get_minimumValue, fset=set_minimumValue, doc=_minimumValueDoc)
-# ATTENTION - Register the Application class with the accessible factory.
-add_accessible_class(interfaces.ATSPI_VALUE, Value)
+# Register the accessible class with the factory.
+accessible_factory.register_accessible_class(interfaces.ATSPI_VALUE, Value)
#END----------------------------------------------------------------------------