[X2Go-Commits] [pyhoca-gui] 10/10: Add support for X2Go KDrive graphical Xsession backend.

git-admin at x2go.org git-admin at x2go.org
Tue Jul 23 21:53:29 CEST 2019


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch master
in repository pyhoca-gui.

commit 21f711d3c84f58dd7c768acfbe72178d4da8b1fe
Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
Date:   Tue Jul 23 21:52:19 2019 +0200

    Add support for X2Go KDrive graphical Xsession backend.
---
 debian/changelog               |  1 +
 pyhoca/wxgui/profilemanager.py | 38 ++++++++++++++++++++++++++++++++++++++
 2 files changed, 39 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 304376b..734adbb 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -28,6 +28,7 @@ pyhoca-gui (0.5.0.9-0x2go1) UNRELEASED; urgency=medium
       left when entering profile manager.
     - Introduce stdout_NotifierPopup fallback class for situations where no
       desktop notification service is running.
+    - Add support for X2Go KDrive graphical Xsession backend.
   * debian/control:
     + Drop python-notify alternative dependency, rely on the GTK-3 Notify
       GObject.
diff --git a/pyhoca/wxgui/profilemanager.py b/pyhoca/wxgui/profilemanager.py
index 94d052d..1cad7ed 100644
--- a/pyhoca/wxgui/profilemanager.py
+++ b/pyhoca/wxgui/profilemanager.py
@@ -261,6 +261,7 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
         self.AutoConnectSessionProfile = wx.CheckBox(self.tab_Session, -1, _(u"Login automatically after %s has started (needs --auto-connect)") % self._PyHocaGUI.appname)
         self.SessionTypeLabel = wx.StaticText(self.tab_Session, -1, _(u"Type")+": ")
         self.SessionType = wx.ComboBox(self.tab_Session, -1, choices=self.sessionChoices.values(), style=wx.CB_DROPDOWN|wx.CB_READONLY)
+        self.SessionTypeKDrive = wx.CheckBox(self.tab_Session, -1, _(u"Use X2Go KDrive graphical backend (experimental)"))
         self.ApplicationLabel = wx.StaticText(self.tab_Session, -1, _(u"Application")+": ")
         self.Application = wx.ComboBox(self.tab_Session, -1, choices=self.applicationChoices.values(), style=wx.CB_DROPDOWN|wx.CB_READONLY)
         self.CommandLabel = wx.StaticText(self.tab_Session, -1, _(u"Custom command")+": ")
@@ -625,6 +626,7 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
         sizer_2_1_1.Add(self.RDPOptions, pos=(7,1), flag=wx.EXPAND, )
         sizer_2_1_1.Add(self.RootlessSession, pos=(8,0), span=(1,2), flag=wx.EXPAND, )
         sizer_2_1_1.Add(self.UsePublishedApplications, pos=(9,0), span=(1,2), flag=wx.EXPAND, )
+        sizer_2_1_1.Add(self.SessionTypeKDrive, pos=(10,0), span=(1,2), flag=wx.EXPAND, )
         sizer_2_1.Add(sizer_2_1_1, flag=wx.EXPAND|wx.ALL, border=7)
         sizer_2.Add(sizer_2_1, proportion=1, flag=wx.EXPAND|wx.ALL, border=5)
         self.tab_Session.SetSizerAndFit(sizer_2)
@@ -979,6 +981,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
 
         self.UsePublishedApplications.SetValue(_published)
         self.Application.SetItems(self.applicationChoices.values())
+        self.SessionTypeKDrive.Enable(True)
+        self.SessionTypeKDrive.SetValue(self.profile_config['kdrive'])
         # XFCE4 has been renamed to XFCE for 0.2.1.0
         if _command == "XFCE4": _command = "XFCE"
         if _command == 'RDP' and self.profile_config['directrdp']:
@@ -990,6 +994,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.Command.SetValue('')
             self.AutoStartSession.Enable(False)
             self.AutoStartSession.SetValue(False)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
         elif _command in self.sessionChoices.keys():
             self.SessionType.SetValue(self.sessionChoices[_command])
             self.Application.SetValue('')
@@ -1006,6 +1012,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.UsePublishedApplications.SetValue(False)
             self.UsePublishedApplications.Enable(False)
             self.RootlessSession.SetValue(True)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
         elif not _command and _published:
             self.SessionType.SetValue(self.sessionChoices['PUBLISHEDAPPLICATIONS'])
             self.UsePublishedApplications.Enable(False)
@@ -1014,6 +1022,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.Command.SetValue('')
             self._last_pubapp_value = True
             self.RootlessSession.SetValue(True)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
         else:
             self.SessionType.SetValue(self.sessionChoices['CUSTOM'])
             self.UsePublishedApplications.SetValue(False)
@@ -1021,6 +1031,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.Command.Enable(True)
             self.Command.SetValue(_command)
             self.RootlessSession.Enable(True)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
 
         if _command == 'XDMCP':
             self.XDMCPServerLabel.Enable(True)
@@ -1110,6 +1122,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
                 self.UsePublishedApplications.Enable(False)
                 self.RootlessSession.SetValue(False)
                 self.RootlessSession.Enable(False)
+                self.SessionTypeKDrive.Enable(False)
+                self.SessionTypeKDrive.SetValue(False)
             else:
                 self.disable_DirectRDP()
                 self._toggle_SetKeyboard()
@@ -1122,6 +1136,9 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
                 self.UsePublishedApplications.Enable(False)
                 self.RootlessSession.SetValue(False)
                 self.RootlessSession.Enable(False)
+                self.SessionTypeKDrive.Enable(False)
+                self.SessionTypeKDrive.SetValue(False)
+
         else:
             self.disable_DirectRDP()
             self._toggle_SetKeyboard()
@@ -1140,6 +1157,7 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
                 self.Esd.Enable(True)
                 self.DefaultSoundPort.Enable(True)
                 self._toggle_DefaultSoundPort()
+
         else:
             self.EnableSound.SetValue(False)
             self.EnableSound.Enable(False)
@@ -1341,6 +1359,7 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
         self.profile_config['name'] = self.ProfileName.GetValue()
         self.profile_config['setsessiontitle'] = self.SetSessionWindowTitle.GetValue()
         _session_type = [ s for s in self.sessionChoices.keys() if self.sessionChoices[s] == self.SessionType.GetValue() ][0]
+        self.profile_config['kdrive'] = self.SessionTypeKDrive.GetValue()
         if self.UseDefaultSessionWindowTitle.GetValue():
             self.profile_config['sessiontitle'] = ''
         else:
@@ -1741,6 +1760,11 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
         if _session_type in defaults.X2GO_DESKTOPSESSIONS.keys():
             self.RootlessSession.SetValue(False)
             self.RootlessSession.Enable(False)
+            self.SessionTypeKDrive.Enable(True)
+            if _session_type in defaults.X2GO_DESKTOPSESSIONS_KDRIVE_PREFERRED.keys():
+                self.SessionTypeKDrive.SetValue(True)
+            else:
+                self.SessionTypeKDrive.SetValue(False)
 
         if _session_type == 'APPLICATION':
             self.ApplicationLabel.Enable(True)
@@ -1751,6 +1775,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
                 self.Application.SetValue(self.applicationChoices['TERMINAL'])
             self.RootlessSession.SetValue(True)
             self.RootlessSession.Enable(False)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
         else:
             self.ApplicationLabel.Enable(False)
             self.Application.Enable(False)
@@ -1764,6 +1790,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
                 self.Command.SetValue('xterm')
                 self.RootlessSession.SetValue(True)
             self.RootlessSession.Enable(True)
+            self.SessionTypeKDrive.Enable(True)
+            self.SessionTypeKDrive.SetValue(False)
         else:
             self.CommandLabel.Enable(False)
             self.Command.Enable(False)
@@ -1775,6 +1803,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.UsePublishedApplications.Enable(False)
             self.RootlessSession.SetValue(False)
             self.RootlessSession.Enable(False)
+            self.SessionTypeKDrive.Enable(True)
+            self.SessionTypeKDrive.SetValue(False)
         else:
             self.XDMCPServerLabel.Enable(False)
             self.XDMCPServer.Enable(False)
@@ -1806,6 +1836,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.UsePublishedApplications.Enable(False)
             self.RootlessSession.SetValue(False)
             self.RootlessSession.Enable(False)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
         elif _session_type == 'RDP':
             self.profile_config_bak['rdpport'] = self.SSHPort.GetValue()
             self.profile_config_bak['directrdpsettings'] = self.RDPOptions.GetValue()
@@ -1826,6 +1858,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.UsePublishedApplications.Enable(False)
             self.RootlessSession.SetValue(False)
             self.RootlessSession.Enable(False)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
         else:
             self.profile_config_bak['rdpport'] = self.SSHPort.GetValue()
             self.profile_config_bak['directrdpsettings'] = self.RDPOptions.GetValue()
@@ -1856,6 +1890,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             self.Command.SetValue('')
             self.RootlessSession.SetValue(True)
             self.RootlessSession.Enable(False)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
         else:
             if self._last_pubapp_value is not None:
                 self.UsePublishedApplications.SetValue(self._last_pubapp_value)
@@ -1879,6 +1915,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog):
             # shadow sessions are always desktop sessions
             self.RootlessSession.SetValue(True)
             self.RootlessSession.Enable(False)
+            self.SessionTypeKDrive.Enable(False)
+            self.SessionTypeKDrive.SetValue(False)
 
             # no sound available with SHADOW sessions
             self.EnableSound.SetValue(False)

--
Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pyhoca-gui.git


More information about the x2go-commits mailing list