eric7/UI/UserInterface.py

branch
eric7
changeset 8571
eb2b840bbf8f
parent 8553
10d31e5ce9e5
child 8580
e91b276e0771
--- a/eric7/UI/UserInterface.py	Fri Sep 03 17:24:57 2021 +0200
+++ b/eric7/UI/UserInterface.py	Fri Sep 03 19:14:20 2021 +0200
@@ -7341,12 +7341,26 @@
         if not Preferences.isConfigured():
             self.__initDebugToolbarsLayout()
             
-            EricMessageBox.information(
-                self,
-                self.tr("First time usage"),
-                self.tr("""eric has not been configured yet. """
-                        """The configuration dialog will be started."""))
+            if Preferences.hasEric6Configuration():
+                yes = EricMessageBox.yesNo(
+                    self,
+                    self.tr("First time usage"),
+                    self.tr("eric7 has not been configured yet but an eric6"
+                            " configuration was found. Shall this be"
+                            " imported?"),
+                    yesDefault=True
+                )
+                if yes:
+                    Preferences.importEric6Configuration()
+            else:
+                EricMessageBox.information(
+                    self,
+                    self.tr("First time usage"),
+                    self.tr("""eric has not been configured yet. """
+                            """The configuration dialog will be started."""))
+            
             self.showPreferences()
+            Preferences.setConfigured()
     
     def checkProjectsWorkspace(self):
         """

eric ide

mercurial