dabo Commit
Revision 4156
Date: 2008-06-18 14:27:40 -0700 (Wed, 18 Jun 2008)
Author: Ed
Trac: http://svn.dabodev.com/trac/dabo/changeset/4156

Changed:
U   trunk/ide/ClassDesignerFormMixin.py

Log:
If you attempt to save a new, unchanged design, the Class Designer will now 
save it. Previously, unchanged designs were not written to disk. Thanks to Nate 
Lowrie for pointing this out.


Diff:
Modified: trunk/ide/ClassDesignerFormMixin.py
===================================================================
--- trunk/ide/ClassDesignerFormMixin.py 2008-06-18 01:16:01 UTC (rev 4155)
+++ trunk/ide/ClassDesignerFormMixin.py 2008-06-18 21:27:40 UTC (rev 4156)
@@ -434,6 +434,7 @@
                
        def onSaveDesign(self, evt, useTmp=False):
                currForm = self.Controller.CurrentForm
+               newFIle = False
                if useTmp:
                        osp = os.path
                        if self._classFile:
@@ -451,6 +452,7 @@
                                        self._classFile = 
self._classFile.rstrip(".")
                                        if not 
self._classFile.endswith(".cdxml"):
                                                self._classFile += ".cdxml"
+                               newFile = True
                        fname = self._classFile
                
                # If there is a code editing form, flush the current page
@@ -469,7 +471,7 @@
                        propDict = propDictCompare = 
self.getClassDesignerDict(obj)
                        self.Controller.saveAllProps = False
 
-               if not useTmp and (propDictCompare == self._savedState):
+               if not useTmp and not newFile and (propDictCompare == 
self._savedState):
                        return
                
                imp = self.Controller.getImportDict(self)




_______________________________________________
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