The branch, build-59a18b6e3b5d3f1dd8f07f26433d37fe5984a57d has been updated via deccf81fc0840af73df45ac47cd49441651025a2 (commit) from b05b4d50225300df7023eea907db9af643c0c2a7 (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/wxgui/frontend.py | 26 +++++++++++++++++++------- pyhoca/wxgui/logon.py | 6 +++--- pyhoca/wxgui/menus_taskbar.py | 12 ++++++++---- 3 files changed, 30 insertions(+), 14 deletions(-) The diff of changes is: diff --git a/pyhoca/wxgui/frontend.py b/pyhoca/wxgui/frontend.py index 2216a38..e0eb80a 100644 --- a/pyhoca/wxgui/frontend.py +++ b/pyhoca/wxgui/frontend.py @@ -475,7 +475,19 @@ class PyHocaGUI(wx.App, x2go.X2goClient): STILL UNDOCUMENTED """ - self._pyhoca_logger('The ,,Share Local Folder\'\' menu item is not implemented yet', loglevel=x2go.log.loglevel_WARN, ) + self.current_profile_name = self._eventid_profilenames_map[evt.GetId()] + self._pyhoca_logger('Evoking file dialog for ,,Share Local Folder\'\' menu item action', loglevel=x2go.log.loglevel_NOTICE, ) + shared_folder = os.path.expanduser('~') + if not os.path.exists(shared_folder): + shared_folder = os.getcwd() + dlg = wx.DirDialog( + self.about, message="%s - share local folder with sessions of this profile" % self.current_profile_name, style=1, defaultPath=shared_folder) + # Show the dialog and retrieve the user response. If it is the OK response, + # process the data. + if dlg.ShowModal() == wx.ID_OK: + # This returns a Python list of files that were selected. + self._X2goClient__share_local_folder_with_session(profile_name=self.current_profile_name, folder_name=str(dlg.GetPath())) + def OnListSessions(self, evt): """\ @@ -538,15 +550,15 @@ class PyHocaGUI(wx.App, x2go.X2goClient): #print 9 def HOOK_on_session_has_started_by_me(self, session_uuid='UNKNOWN', profile_name='UNKNOWN', session_name='UNKNOWN'): - self.notifier.send(profile_name, 'New X2go session starting up...\n%s' % session_name, icon='session_start', timeout=5000) + self.notifier.send('%s - start' % profile_name, 'New X2go session starting up...\n%s' % session_name, icon='session_start', timeout=5000) def HOOK_on_session_has_started_by_other(self, session_uuid='UNKNOWN', profile_name='UNKNOWN', session_name='UNKNOWN'): - self.notifier.send(profile_name, 'Another client started X2go session\n%s' % session_name, icon='session_start', timeout=5000) + self.notifier.send('%s - start' % profile_name, 'Another client started X2go session\n%s' % session_name, icon='session_start', timeout=5000) def HOOK_on_session_has_resumed_by_me(self, session_uuid='UNKNOWN', profile_name='UNKNOWN', session_name='UNKNOWN'): - self.notifier.send(profile_name, 'Resuming X2go session...\n%s' % session_name, icon='session_resume', timeout=5000) + self.notifier.send('%s - resume' % profile_name, 'Resuming X2go session...\n%s' % session_name, icon='session_resume', timeout=5000) def HOOK_on_session_has_resumed_by_other(self, session_uuid='UNKNOWN', profile_name='UNKNOWN', session_name='UNKNOWN'): - self.notifier.send(profile_name, 'Another client resumed X2go session\n%s' % session_name, icon='session_resume', timeout=5000) + self.notifier.send('%s - resume' % profile_name, 'Another client resumed X2go session\n%s' % session_name, icon='session_resume', timeout=5000) def HOOK_on_session_has_been_suspended(self, session_uuid='UNKNOWN', profile_name='UNKNOWN', session_name='UNKNOWN'): - self.notifier.send(profile_name, 'X2go Session has been suspended\n%s' % session_name, icon='session_suspend', timeout=5000) + self.notifier.send('%s - suspend' % profile_name, 'X2go Session has been suspended\n%s' % session_name, icon='session_suspend', timeout=5000) def HOOK_on_session_has_terminated(self, session_uuid='UNKNOWN', profile_name='UNKNOWN', session_name='UNKNOWN'): # avoid notification if X2goClient.clean_sessions has been used to terminate sessions if self._hide_notifications_map.has_key(profile_name) and session_name in self._hide_notifications_map[profile_name]: @@ -554,4 +566,4 @@ class PyHocaGUI(wx.App, x2go.X2goClient): if not self._hide_notifications_map[profile_name]: del self._hide_notifications_map[profile_name] else: - self.notifier.send(profile_name, 'X2go Session has terminated\n%s' % session_name, icon='session_terminate', timeout=5000) + self.notifier.send('%s - terminate' % profile_name, 'X2go Session has terminated\n%s' % session_name, icon='session_terminate', timeout=5000) diff --git a/pyhoca/wxgui/logon.py b/pyhoca/wxgui/logon.py index 0f72434..7e3a97f 100644 --- a/pyhoca/wxgui/logon.py +++ b/pyhoca/wxgui/logon.py @@ -68,7 +68,7 @@ class PyHocaGUI_DialogBoxPassword(wx.Dialog): self.current_profile_config = self._PyHocaGUI.session_profiles.get_profile_config(profile_name) if self.sshproxy_auth: - size=(210, 190) + size=(450, 190) else: size=(210, 150) @@ -90,8 +90,8 @@ class PyHocaGUI_DialogBoxPassword(wx.Dialog): # widgets if self.sshproxy_auth: - self.headerLbl = wx.StaticText(self, wx.ID_ANY, 'Session login:', size=(160, -1)) - self.sshProxyHeaderLbl = wx.StaticText(self, wx.ID_ANY, 'SSH proxy server login:', size=(160, -1)) + self.headerLbl = wx.StaticText(self, wx.ID_ANY, 'Session login:', size=(200, -1)) + self.sshProxyHeaderLbl = wx.StaticText(self, wx.ID_ANY, 'SSH proxy server login:', size=(200, -1)) self.headerLbl.SetFont(wx.Font(8, wx.DEFAULT, wx.NORMAL, wx.FONTWEIGHT_BOLD, 0, "")) self.sshProxyHeaderLbl.SetFont(wx.Font(8, wx.DEFAULT, wx.NORMAL, wx.FONTWEIGHT_BOLD, 0, "")) self.sshProxyUserLbl = wx.StaticText(self, wx.ID_ANY, 'Username:', size=(80, -1)) diff --git a/pyhoca/wxgui/menus_taskbar.py b/pyhoca/wxgui/menus_taskbar.py index cecb221..ac1860f 100644 --- a/pyhoca/wxgui/menus_taskbar.py +++ b/pyhoca/wxgui/menus_taskbar.py @@ -199,13 +199,17 @@ class PyHocaGUI_Menu_TaskbarSessionProfile(wx.Menu): ) ) - self.Append(id=ID_CLEANSESSIONS, text="&Clean all sessions") - self.AppendSeparator() + if _session_list.keys(): + self.Append(id=ID_CLEANSESSIONS, text="&Clean all sessions") + self.AppendSeparator() self.Append(id=ID_EDITPROFILEWHILECONNECTED, text="Customize &profile") - self.Append(id=ID_SHARELOCALFOLDER, text="Share local &folder") + _share_folder = self.Append(id=ID_SHARELOCALFOLDER, text="Share local &folder") self.AppendSeparator() self.Append(id=ID_DISCONNECT, text="&Disconnect from Server") + if not self._PyHocaGUI._X2goClient__client_associated_sessions_of_profile_name(profile_name): + _share_folder.Enable(False) + self._PyHocaGUI.current_profile_name = profile_name self._PyHocaGUI.Bind(wx.EVT_MENU, self._PyHocaGUI.OnSessionStart, id=ID_SESSIONSTART) self._PyHocaGUI.Bind(wx.EVT_MENU, self._PyHocaGUI.OnCleanSessions, id=ID_CLEANSESSIONS) @@ -289,7 +293,7 @@ class PyHocaGUI_Menu_TaskbarSessionManager(wx.Menu): ID_AUTHENTICATE = wx.NewId() ID_EXIT = wx.NewId() - _auth_menu_text = self._PyHocaGUI.start_on_connect and 'Start X2go Session' or 'Authenticate X2go Server' + _auth_menu_text = self._PyHocaGUI.start_on_connect and 'Start/Resume Session' or 'Connect Server' self.AppendMenu(id=ID_AUTHENTICATE, text=_auth_menu_text, submenu=PyHocaGUI_Menu_TaskbarProfileNames(self._PyHocaGUI, 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)).