src/eric7/Debugger/DebugServer.py

branch
eric7-maintenance
changeset 9442
906485dcd210
parent 9305
3b7ef53c34c7
parent 9430
aef6b11d4ecd
child 9549
67295777d9fe
--- a/src/eric7/Debugger/DebugServer.py	Sun Oct 02 11:44:07 2022 +0200
+++ b/src/eric7/Debugger/DebugServer.py	Sat Oct 29 15:24:59 2022 +0200
@@ -14,14 +14,14 @@
 from PyQt6.QtCore import pyqtSignal, pyqtSlot, QModelIndex
 from PyQt6.QtNetwork import QTcpServer, QHostAddress, QHostInfo, QNetworkInterface
 
-from EricWidgets.EricApplication import ericApp
-from EricWidgets import EricMessageBox
+from eric7.EricWidgets.EricApplication import ericApp
+from eric7.EricWidgets import EricMessageBox
 
 from .BreakPointModel import BreakPointModel
 from .WatchPointModel import WatchPointModel
 from . import DebugClientCapabilities
 
-import Preferences
+from eric7 import Preferences
 
 
 DebuggerInterfaces = {
@@ -400,7 +400,7 @@
         Private method to register the available internal debugger interfaces.
         """
         for name, interface in DebuggerInterfaces.items():
-            modName = "Debugger.{0}".format(interface)
+            modName = "eric7.Debugger.{0}".format(interface)
             mod = __import__(modName)
             components = modName.split(".")
             for comp in components[1:]:
@@ -2179,3 +2179,15 @@
             self.debuggerInterface.remoteNoDebugList(
                 debuggerId, self.__multiprocessNoDebugList
             )
+
+    def getProjectEnvironmentString(self):
+        """
+        Public method to get the string for the project environment.
+
+        @return string for the project environment
+        @rtype str
+        """
+        if ericApp().getObject("Project").isOpen():
+            return self.tr("<project>")
+        else:
+            return ""

eric ide

mercurial