daboide Commit
Revision 321
Date: 2006-01-11 08:23:00 -0800 (Wed, 11 Jan 2006)
Author: ed

Changed:
U   trunk/DesignerFormMixin.py

Log:
You can now run apps saved to directories other than the default Designer 
directory.


Diff:
Modified: trunk/DesignerFormMixin.py
===================================================================
--- trunk/DesignerFormMixin.py  2006-01-11 03:55:12 UTC (rev 320)
+++ trunk/DesignerFormMixin.py  2006-01-11 16:23:00 UTC (rev 321)
@@ -1,4 +1,5 @@
 import os
+import sys
 import dabo
 from dabo.dLocalize import _
 from dabo.lib.utils import padl
@@ -174,6 +175,10 @@
        def onRunDesign(self, evt):
                # First, make sure that it's been saved
                self.onSaveDesign(None)
+               pth = os.path.split(self._classFile)[0]
+               syspth = sys.path
+               if pth not in sys.path:
+                       sys.path.append(pth)
                frm = dui.createForm(self._classFile)
                frm.isDemoTest = True
                frm.Visible = True




_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev

Reply via email to