dogtail-devel [Bug 439531] New: Unable to define instance variables in Accessible



If you have any questions why you received this email, please see the text at
the end of this email. Replies to this email are NOT read, please see the text
at the end of this email. You can add comments to this bug at:
  http://bugzilla.gnome.org/show_bug.cgi?id=439531

  at-spi | python-bindings | Ver: unspecified
           Summary: Unable to define instance variables in Accessible
           Product: at-spi
           Version: unspecified
          Platform: Other
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: Normal
         Component: python-bindings
        AssignedTo: li yuan sun com
        ReportedBy: zcerza redhat com
         QAContact: li yuan sun com
                CC: dogtail-devel-list gnome org
     GNOME version: Unspecified
   GNOME milestone: Unspecified


I'm starting work on porting dogtail to pyatspi from pyspi. The way I'm
currently doing the port is by converting dogtail.tree.Node into another mixin
for Accessibility.Accessible, and doing the same for most of the other classes
in dogtail.tree.

The use of __slots__ in _AccessibleMixin means that I can't define any instance
variables. Node currently uses (I'm pretty sure only) one instance variable,
called debugName, which is a string that describes how the Accessible was
"found" - e.g. "child of foo named bar". It makes for very nice logfiles in
case something blows up. I'm currently just patching pyatspi to add 'debugName'
to __slots__, but I don't feel it's the right way to do this.

Pete suggested adding an addSlot method somewhere, which would work if it was
called by dogtail (or others) before any Accessibles were instantiated. But
what about just adding '__dict__' to slots, so that instance variables could be
added without any special calls beforehand?


-- 
See http://bugzilla.gnome.org/page.cgi?id=email.html for more info about why you received
this email, why you can't respond via email, how to stop receiving
emails (or reduce the number you receive), and how to contact someone
if you are having problems with the system.

You can add comments to this bug at http://bugzilla.gnome.org/show_bug.cgi?id=439531.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]