dabo Commit
Revision 6136
Date: 2010-10-23 10:38:43 -0700 (Sat, 23 Oct 2010)
Author: Ed
Trac: http://trac.dabodev.com/changeset/6136

Changed:
U   trunk/dabo/ui/uiwx/dEditor.py

Log:
Added optional 'multiple' parameter to promptForFileName().

Diff:
Modified: trunk/dabo/ui/uiwx/dEditor.py
===================================================================
--- trunk/dabo/ui/uiwx/dEditor.py       2010-10-23 16:27:02 UTC (rev 6135)
+++ trunk/dabo/ui/uiwx/dEditor.py       2010-10-23 17:38:43 UTC (rev 6136)
@@ -1374,10 +1374,13 @@
                return dabo.ui.areYouSure(s)
 
 
-       def promptForFileName(self, prompt=None, saveAs=False, path=None):
+       def promptForFileName(self, prompt=None, saveAs=False, path=None, 
multiple=False):
                """Prompt the user for a file name."""
                if prompt is None:
-                       prompt = _("Select a file")
+                       if multiple:
+                               prompt = _("Select a file (or files)")
+                       else:
+                               prompt = _("Select a file")
                if path is None:
                        try:
                                drct = self._curdir
@@ -1390,7 +1393,8 @@
                        func = dabo.ui.getSaveAs
                else:
                        func = dabo.ui.getFile
-               fname = func("py", "txt", "cdxml", "cnxml", "mnxml", "rfxml", 
"*", message=prompt, defaultPath=drct)
+               fname = func("py", "txt", "cdxml", "cnxml", "mnxml", "rfxml", 
"*", message=prompt,
+                               defaultPath=drct, multiple=multiple)
                return fname
 
 



_______________________________________________
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