[X2Go-Commits] pyhoca-gui.git - build-59a18b6e3b5d3f1dd8f07f26433d37fe5984a57d (branch) updated: a7cb4fcdec26ce27a4a526f75e70d2294b7854ab
X2Go dev team
git-admin at x2go.org
Tue Aug 27 13:20:55 CEST 2013
The branch, build-59a18b6e3b5d3f1dd8f07f26433d37fe5984a57d has been updated
via a7cb4fcdec26ce27a4a526f75e70d2294b7854ab (commit)
from 02aa1e0b7e8b5b32dcd0f0d3beab99a25dacaef5 (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 -----------------------------------------------------------------
-----------------------------------------------------------------------
Summary of changes:
pyhoca-gui | 25 ++++++++++++++---------
pyhoca/wxgui/frontend.py | 49 +++++++++++++++++++++++++---------------------
2 files changed, 43 insertions(+), 31 deletions(-)
The diff of changes is:
diff --git a/pyhoca-gui b/pyhoca-gui
index 7cb33da..af40f1b 100755
--- a/pyhoca-gui
+++ b/pyhoca-gui
@@ -183,9 +183,9 @@ backend_options = [
{'args':['--backend-serversessioninfo'], 'default': None, 'metavar': 'SERVERSESSIONINFO_BACKEND', 'choices': BACKENDS_TERMINALSESSION.keys(), 'help': 'force usage of a certain SERVERSESSIONINFO_BACKEND (do not use this unless you know exactly what you are doing)', },
{'args':['--backend-serversessionlist'], 'default': None, 'metavar': 'SERVERSESSIONLIST_BACKEND', 'choices': BACKENDS_TERMINALSESSION.keys(), 'help': 'force usage of a certain SERVERSESSIONLIST_BACKEND (do not use this unless you know exactly what you are doing)', },
{'args':['--backend-proxy'], 'default': None, 'metavar': 'PROXY_BACKEND', 'choices': BACKENDS_PROXY.keys(), 'help': 'force usage of a certain PROXY_BACKEND (do not use this unless you know exactly what you are doing)', },
- {'args':['--backend-sessionprofiles'], 'default': None, 'metavar': 'SESSIONPROFILES_BACKEND', 'choices': _config_backends, 'help': 'use given backend for accessing session profiles, available backends on your system: %s, (default: %s)' % (', '.join(_config_backends), _profiles_backend_default), },
- {'args':['--backend-clientsettings'], 'default': None, 'metavar': 'CLIENTSETTINGS_BACKEND', 'choices': _config_backends, 'help': 'use given backend for accessing the client settings configuration, available backends on your system: %s, (default: %s)' % (', '.join(_config_backends), _settings_backend_default), },
- {'args':['--backend-clientprinting'], 'default': None, 'metavar': 'CLIENTPRINTING_BACKEND', 'choices': _config_backends, 'help': 'use given backend for accessing the client printing configuration, available backends on your system: %s, (default: %s)' % (', '.join(_config_backends), _printing_backend_default), },
+ {'args':['--backend-sessionprofiles'], 'default': None, 'metavar': 'SESSIONPROFILES_BACKEND', 'choices': _config_backends, 'help': 'use given backend for accessing session profiles, available backends on your system: %s (default: %s)' % (', '.join(_config_backends), _profiles_backend_default), },
+ {'args':['--backend-clientsettings'], 'default': None, 'metavar': 'CLIENTSETTINGS_BACKEND', 'choices': _config_backends, 'help': 'use given backend for accessing the client settings configuration, available backends on your system: %s (default: %s)' % (', '.join(_config_backends), _settings_backend_default), },
+ {'args':['--backend-clientprinting'], 'default': None, 'metavar': 'CLIENTPRINTING_BACKEND', 'choices': _config_backends, 'help': 'use given backend for accessing the client printing configuration, available backends on your system: %s (default: %s)' % (', '.join(_config_backends), _printing_backend_default), },
]
if _X2GOCLIENT_OS == 'Windows':
@@ -193,11 +193,12 @@ if _X2GOCLIENT_OS == 'Windows':
{'args':['--start-xserver'], 'default': False, 'action': 'store_true', 'help': 'start the XServer before starting PyHoca-GUI, detect best XServer automatically, if more than one XServer is installed on your system', },
{'args':['-X', '--preferred-xserver'], 'default': None, 'metavar': 'XSERVER', 'choices': _known_xservers, 'help': 'start either of the currently supported XServers: %s -- make sure your preferred XServer is installed on your system' % _known_xservers, },
]
- portable_options = [
- {'args':['--config-rootdir'], 'default': os.path.join(os.environ['USERPROFILE'], '.x2goclient'), 'help': 'define an alternative location where to find plain text config files (default: %USERPROFILE/.x2goclient). This option is only effective when used together with ,,--backend-profiles FILE'')', },
- {'args':['--sessions-rootdir'], 'default': os.path.join(os.environ['USERPROFILE'], '.x2go'), 'help': 'define an alternative location for session runtime files (default: %USERPROFILE%\\.x2go', },
- {'args':['--ssh-rootdir'], 'default': os.path.join(os.environ['USERPROFILE'], '.x2go', '.ssh'), 'help': 'define an alternative location for SSH files (default: %USERPROFILE%\\.x2go\\.ssh', },
- ]
+
+portable_options = [
+ {'args':['--client-rootdir'], 'default': None, 'help': 'define an alternative location where to find plain text config files (default: <HOME>/.x2goclient). This option will set ,,--backend-profiles FILE\'\', ,,--backend-clientsettings FILE\'\' and ,,--backend-clientprinting FILE\'\'', },
+ {'args':['--sessions-rootdir'], 'default': None, 'help': 'define an alternative location for session runtime files'},
+ {'args':['--ssh-rootdir'], 'default': None, 'help': 'define an alternative location for SSH files', },
+ ]
def parseargs():
@@ -210,6 +211,7 @@ def parseargs():
add_help=True, argument_default=None)
p_debugopts = p.add_argument_group('Debug options')
p_guiopts = p.add_argument_group('PyHoca-GUI options')
+ p_portableopts = p.add_argument_group('Portable application support')
p_backendopts = p.add_argument_group('Python X2go backend options (for experts only)')
if _X2GOCLIENT_OS == 'Windows':
@@ -217,7 +219,7 @@ def parseargs():
p_portableopts = p.add_argument_group('File locations for portable setups (MS Windows only)')
_option_groups = ((p_guiopts, x2go_gui_options), (p_debugopts, debug_options), (p_xserveropts, xserver_options), (p_portableopts, portable_options), (p_backendopts, backend_options), )
else:
- _option_groups = ((p_guiopts, x2go_gui_options), (p_debugopts, debug_options), (p_backendopts, backend_options), )
+ _option_groups = ((p_guiopts, x2go_gui_options), (p_debugopts, debug_options), (p_portableopts, portable_options), (p_backendopts, backend_options), )
for (p_group, opts) in _option_groups:
required = False
for opt in opts:
@@ -264,6 +266,11 @@ def parseargs():
if _X2GOCLIENT_OS == 'Windows' and not a.start_xserver:
os.environ.update({'DISPLAY': 'localhost:0'})
+ if a.client_rootdir:
+ a.backend_sessionprofiles='FILE'
+ a.backend_clientsettings='FILE'
+ a.backend_clientprinting='FILE'
+
return a, logger, liblogger
def main():
diff --git a/pyhoca/wxgui/frontend.py b/pyhoca/wxgui/frontend.py
index ccbd40c..f305587 100644
--- a/pyhoca/wxgui/frontend.py
+++ b/pyhoca/wxgui/frontend.py
@@ -91,8 +91,6 @@ class PyHocaGUI(wx.App, x2go.X2goClient):
self._pyhoca_liblogger = copy.deepcopy(liblogger)
wx.App.__init__(self)
- # panel is a generic panel that allows to influence the mouse cursor when it hovers
- # above the tray icon (and any other element on the desktop we created)
self.Bind(wx.EVT_IDLE, self.OnIdle)
def OnInit(self):
@@ -126,6 +124,13 @@ class PyHocaGUI(wx.App, x2go.X2goClient):
if self.args.backend_clientprinting is not None:
_x2goclient_kwargs['printing_backend'] = self.args.backend_clientprinting
+ if self.args.client_rootdir is not None:
+ _x2goclient_kwargs['client_rootdir'] = self.args.client_rootdir
+ if self.args.sessions_rootdir is not None:
+ _x2goclient_kwargs['sessions_rootdir'] = self.args.sessions_rootdir
+ if self.args.ssh_rootdir is not None:
+ _x2goclient_kwargs['ssh_rootdir'] = self.args.ssh_rootdir
+
if x2go.X2GOCLIENT_OS == 'Windows':
_x2goclient_kwargs['start_xserver'] = self.args.start_xserver
@@ -509,23 +514,23 @@ class PyHocaGUI(wx.App, x2go.X2goClient):
# this hook gets called from Python X2go classes if a print job is coming in and the print action is ,,DIALOG''...
def HOOK_open_print_dialog(self, filename, profile_name='UNKNOWN', session_name='UNKNOWN'):
- self.notifier.send('%s - print job' % profile_name, 'Opening print job dialog...\n%s' % session_name, icon='session_printing', timeout=5000)
-
- _p = wx.Dialog(None, -1, '%s (%s)' % (session_name, profile_name), size=(450,380))
- print 1
- _p_data = wx.PrintData()
- print 2
- _p_data.SetFilename(filename)
- print 3
- _p_dialogdata = wx.PrintDialogData(_p_data)
- print 4
- #_p_dialog = wx.PrintDialog(_p, _p_dialogdata)
- print 5
- #_p_dialog.ShowModal()
- print 6
- #_p.Fit()
- print 7
- #_p.Layout()
- print 8
- #_p.Show(True)
- print 9
+ self.notifier.send('%s - print job' % profile_name, 'Opening print job dialog not implemented yet!!!\n%s' % session_name, icon='session_printing', timeout=5000)
+
+ #_p = wx.Dialog(None, -1, '%s (%s)' % (session_name, profile_name), size=(450,380))
+ #print 1
+ #_p_data = wx.PrintData()
+ #print 2
+ #_p_data.SetFilename(filename)
+ #print 3
+ #_p_dialogdata = wx.PrintDialogData(_p_data)
+ #print 4
+ ##_p_dialog = wx.PrintDialog(_p, _p_dialogdata)
+ #print 5
+ ##_p_dialog.ShowModal()
+ #print 6
+ ##_p.Fit()
+ #print 7
+ ##_p.Layout()
+ #print 8
+ ##_p.Show(True)
+ #print 9
hooks/post-receive
--
pyhoca-gui.git (Python X2Go Client (wxPython GUI))
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 "pyhoca-gui.git" (Python X2Go Client (wxPython GUI)).
More information about the x2go-commits
mailing list