The branch, master has been updated via c23d9f46f3b6fd8c4155db7af689e15f76096a24 (commit) from ef4ae509162b4b5a13c319e7e87e584f3837b53b (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit c23d9f46f3b6fd8c4155db7af689e15f76096a24 Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Wed Apr 18 18:25:37 2012 +0200 Provide X2goSession.get_session_type() method. ----------------------------------------------------------------------- Summary of changes: debian/changelog | 1 + x2go/backends/terminal/_stdout.py | 7 +++++++ x2go/session.py | 18 ++++++++++++++++++ 3 files changed, 26 insertions(+), 0 deletions(-) The diff of changes is: diff --git a/debian/changelog b/debian/changelog index 2b9f7cb..8bdba1c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -111,6 +111,7 @@ python-x2go (0.1.2.0-0~x2go1) UNRELEASED; urgency=low around faulty abortion of client implementations. - Handle detection of free TCP/IP X display port far more intelligently. - On unused port detection bind to 127.0.0.1 by default. + - Provide X2goSession.get_session_type() method. * Depend on python-xlib. -- Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Sat, 28 Sep 2012 01:44:21 +0100 diff --git a/x2go/backends/terminal/_stdout.py b/x2go/backends/terminal/_stdout.py index 9e9b801..095445e 100644 --- a/x2go/backends/terminal/_stdout.py +++ b/x2go/backends/terminal/_stdout.py @@ -407,6 +407,13 @@ class X2goTerminalSessionSTDOUT(object): """ return self.params.cmd + def get_session_type(self) + """\ + STILL UNDOCUMENTED + + """ + return self.session_type + def start_sound(self): """\ Initialize Paramiko/SSH reverse forwarding tunnel for X2Go sound. diff --git a/x2go/session.py b/x2go/session.py index d3d7d9e..3e134d8 100644 --- a/x2go/session.py +++ b/x2go/session.py @@ -791,6 +791,24 @@ class X2goSession(object): return None __get_session_cmd = get_session_cmd + def get_session_type(self): + """\ + Retrieve the session type of a session (R, D, S or P). + + R: rootless session + D: desktop session + S: shadow session + P: session in published applications mode + + @return: session type + @rtype: C{str} + + """ + if self.has_terminal_session(): + return self.terminal_session.get_session_type() + else: + return None + def get_session_title(self): """\ Retrieve the session window title of this hooks/post-receive -- python-x2go.git (Python X2Go Client API) This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "python-x2go.git" (Python X2Go Client API).