dabo Commit
Revision 4362
Date: 2008-08-06 10:26:28 -0700 (Wed, 06 Aug 2008)
Author: Nate
Trac: http://svn.dabodev.com/trac/dabo/changeset/4362

Changed:
U   trunk/ide/ClassDesignerComponents.py

Log:
This fixes the errors I was getting upon saving a dTreeView widget in a class.  
dNode objects don't have a Parent property, so we are catching an 
AttributeError now instead of an IndexError.  This was introduced in 4131.

Note, there is still a display problem with the nodes upon opening the class in 
the class designer.  Ed, are the dNode classes supposed to have ????? for the 
parent classID?

Diff:
Modified: trunk/ide/ClassDesignerComponents.py
===================================================================
--- trunk/ide/ClassDesignerComponents.py        2008-08-06 16:00:02 UTC (rev 
4361)
+++ trunk/ide/ClassDesignerComponents.py        2008-08-06 17:26:28 UTC (rev 
4362)
@@ -66,11 +66,11 @@
                                        # First-time save. Get the classID of 
the parent
                                        try:
                                                classID = 
self.Parent.classID.split("-")[0]
-                                       except IndexError:
+                                       except AttributeError:
                                                # Try the sizer
                                                        try:
                                                                classID = 
self.ControllingSizer.classID.split("-")[0]
-                                                       except IndexError:
+                                                       except AttributeError:
                                                                classID = 
"?????"
                                ra["classID"] = "%s-%s" % (classID, myID)
                                self.classID = ra["classID"]




_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message: http://leafe.com/archives/byMID/[EMAIL PROTECTED]

Reply via email to