/usr/lib/python2.7/dist-packages/dogtail/wrapped.py is in python-dogtail 0.9.0-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | """
Superclasses for application wrappers
Subclass these classes if you want to create application wrappers, e.g.:
http://svn.gnome.org/viewvc/dogtail-tests/trunk/appwrappers/dogtail/appwrappers/gedit.py?view=markup
"""
__author__ = "Zack Cerza <zcerza@redhat.com>"
import Accessibility
def makeWrapperClass(wrappedClass, name): # pragma: no cover
class klass(object):
def __init__(self, obj):
self.obj = obj
def __getattr__(self, name):
if name == 'obj':
return self.__dict__['obj']
return getattr(self.obj, name)
def __setattr__(self, name, value):
if name == 'obj':
self.__dict__['obj'] = value
else:
return setattr(self.obj, name, value)
klass.__name__ = name
return klass
Application = makeWrapperClass(Accessibility.Application,
"WrappedApplication")
Node = makeWrapperClass(Accessibility.Accessible, "WrappedNode")
|