src/eric7/Preferences/ConfigurationPages/EricServerPage.py

branch
server
changeset 10531
3308e8349e4c
child 10555
08e853c0c77b
diff -r 684f491a3bfc -r 3308e8349e4c src/eric7/Preferences/ConfigurationPages/EricServerPage.py
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/eric7/Preferences/ConfigurationPages/EricServerPage.py	Mon Jan 29 19:50:44 2024 +0100
@@ -0,0 +1,49 @@
+# -*- coding: utf-8 -*-
+
+# Copyright (c) 2024 Detlev Offenbach <detlev@die-offenbachs.de>
+#
+
+"""
+Module implementing the eric-ide server related settings.
+"""
+
+from eric7 import Preferences
+
+from .ConfigurationPageBase import ConfigurationPageBase
+from .Ui_EricServerPage import Ui_EricServerPage
+
+
+class EricServerPage(ConfigurationPageBase, Ui_EricServerPage):
+    """
+    Class implementing the eric-ide server related settings.
+    """
+
+    def __init__(self):
+        """
+        Constructor
+        """
+        super().__init__()
+        self.setupUi(self)
+        self.setObjectName("EricServerPage")
+
+        # set initial values
+        self.timeoutSpinBox.setValue(Preferences.getEricServer("ConnectionTimeout"))
+
+    def save(self):
+        """
+        Public slot to save the Cooperation configuration.
+        """
+        Preferences.setEricServer("ConnectionTimeout", self.timeoutSpinBox.value())
+
+
+def create(dlg):  # noqa: U100
+    """
+    Module function to create the configuration page.
+
+    @param dlg reference to the configuration dialog
+    @type ConfigurationDialog
+    @return reference to the instantiated page
+    @rtype ConfigurationPageBase
+    """
+    page = EricServerPage()
+    return page

eric ide

mercurial