Don't permit to use non ASCII characters.
authorduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 24 Apr 2009 13:49:52 +0000 (13:49 +0000)
committerduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 24 Apr 2009 13:49:52 +0000 (13:49 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2662 38d2e660-2303-0410-9eaa-f027e97ec537

wizard/BFolderPage.py

index dce305e0d2c0127f57ead17829384a07faeb5af0..b6038ae31b6b37e2e6a9e9e2965c49f0ee9e5f19 100644 (file)
@@ -91,6 +91,11 @@ class BFolderPage(BWizardPage):
         """
         Slot called when the project name is changed manually by the user.
         """
+        try:
+            name = unicode(name).encode("ascii")
+        except UnicodeEncodeError:
+            name = self._project_name
+            self.pageContent.nameEdit.setText(name)
         self._project_name = unicode(name).replace(" ", "_")
         self.setProjectPath()