The branch, master has been updated via a7df5d3b05ed3f5c46b8ca19d6811fd4f2302d22 (commit) from 2d7eacbe52f98d4d25b17cf61f38a609bd1375ca (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 a7df5d3b05ed3f5c46b8ca19d6811fd4f2302d22 Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Wed Nov 30 16:53:13 2011 +0100 Drop handling of session icon, not used in pyhoca-gui, anyway. Fix profile manager window size (shrinking for usage on netbooks). ----------------------------------------------------------------------- Summary of changes: debian/changelog | 2 + pyhoca/wxgui/profilemanager.py | 82 ++++++++++++++++++++-------------------- 2 files changed, 43 insertions(+), 41 deletions(-) The diff of changes is: diff --git a/debian/changelog b/debian/changelog index fc66b54..55cd981 100644 --- a/debian/changelog +++ b/debian/changelog @@ -6,6 +6,8 @@ pyhoca-gui (0.1.0.11-0~x2go1) UNRELEASED; urgency=low - Add switch that enables/disablee custom/server-side session window titles. - Update of i18n files: en, de, es. + - Drop handling of session icon, not used in pyhoca-gui, anyway. + - Fix profile manager window size (shrinking for usage on netbooks). * Depend on Python X2Go 0.1.1.9. -- Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Wed, 09 Nov 2011 03:13:09 +0100 diff --git a/pyhoca/wxgui/profilemanager.py b/pyhoca/wxgui/profilemanager.py index f6c77f6..91f1ef3 100644 --- a/pyhoca/wxgui/profilemanager.py +++ b/pyhoca/wxgui/profilemanager.py @@ -151,16 +151,16 @@ class PyHocaGUI_ProfileManager(wx.Dialog): ### self.ProfileNameLabel = wx.StaticText(self.tab_Session, -1, _(u"Name")+":") self.ProfileName = wx.TextCtrl(self.tab_Session, -1, "") - _share_location = os.path.split(_icons_location)[0] - if 'icon' in self.profile_config: - path_to_icon = self.profile_config['icon'] - path_to_icon = path_to_icon.lstrip(':') - path_to_icon = os.path.join(os.path.normpath(_share_location), os.path.normpath(path_to_icon)) - if not os.path.exists(path_to_icon) or not 'icon' in self.profile_config: - path_to_icon = os.path.normpath('%s/icons/PyHoca/128x128/pyhoca-session.png' % _share_location) - self.IconPath = path_to_icon - self.IconButtonLabel = wx.StaticText(self.tab_Session, -1, _(u"Icon")+':') - self.IconButton = wx.BitmapButton(self.tab_Session, -1, wx.Bitmap(path_to_icon, wx.BITMAP_TYPE_ANY)) + #_share_location = os.path.split(_icons_location)[0] + #if 'icon' in self.profile_config: + # path_to_icon = self.profile_config['icon'] + # path_to_icon = path_to_icon.lstrip(':') + # path_to_icon = os.path.join(os.path.normpath(_share_location), os.path.normpath(path_to_icon)) + #if not os.path.exists(path_to_icon) or not 'icon' in self.profile_config: + # path_to_icon = os.path.normpath('%s/icons/PyHoca/128x128/pyhoca-session.png' % _share_location) + #self.IconPath = path_to_icon + #self.IconButtonLabel = wx.StaticText(self.tab_Session, -1, _(u"Icon")+':') + #self.IconButton = wx.BitmapButton(self.tab_Session, -1, wx.Bitmap(path_to_icon, wx.BITMAP_TYPE_ANY), size=(48,48)) self.SetSessionWindowTitle = wx.CheckBox(self.tab_Session, -1, _(u"Set session window title (leave field below empty for default title from server)")+':') self.SessionWindowTitleLabel = wx.StaticText(self.tab_Session, -1, _(u"Session window title")+":") self.SessionWindowTitle = wx.TextCtrl(self.tab_Session, -1, "") @@ -282,7 +282,7 @@ class PyHocaGUI_ProfileManager(wx.Dialog): self.__do_layout() self.__update_fields() - self.Bind(wx.EVT_BUTTON, self.OnIconChange, self.IconButton) + #self.Bind(wx.EVT_BUTTON, self.OnIconChange, self.IconButton) self.Bind(wx.EVT_COMBOBOX, self.OnSessionTypeSelected, self.SessionType) self.Bind(wx.EVT_CHECKBOX, self.OnSetSessionWindowTitle, self.SetSessionWindowTitle) self.Bind(wx.EVT_BUTTON, self.OnSSHKeyFileBrowse, self.SSHKeyFileBrowseButton) @@ -336,7 +336,7 @@ class PyHocaGUI_ProfileManager(wx.Dialog): self.SetSessionWindowTitle.SetMinSize((-1, _textfield_height)) self.SessionWindowTitleLabel.SetMinSize((160, 16)) self.SessionWindowTitle.SetMinSize((320, _textfield_height)) - self.IconButton.SetSize(self.IconButton.GetBestSize()) + #self.IconButton.SetSize(self.IconButton.GetBestSize()) self.SessionTypeLabel.SetMinSize((120, 16)) self.SessionType.SetMinSize((-1, _textfield_height)) self.SessionType.SetSelection(5) @@ -420,11 +420,11 @@ class PyHocaGUI_ProfileManager(wx.Dialog): # SESSION TAB sizer_1 = wx.BoxSizer(wx.VERTICAL) sizer_1_1 = wx.StaticBoxSizer(self.staticbox_Profile, wx.VERTICAL) - sizer_1_1_1 = wx.FlexGridSizer(2, 2, 7, 9) + sizer_1_1_1 = wx.FlexGridSizer(1, 2, 7, 9) sizer_1_1_1.Add(self.ProfileNameLabel, flag=wx.ALIGN_CENTRE_VERTICAL) sizer_1_1_1.Add(self.ProfileName) - sizer_1_1_1.Add(self.IconButtonLabel, flag=wx.TOP) - sizer_1_1_1.Add(self.IconButton) + #sizer_1_1_1.Add(self.IconButtonLabel, flag=wx.TOP) + #sizer_1_1_1.Add(self.IconButton) sizer_1_1_2 = wx.BoxSizer(wx.HORIZONTAL) sizer_1_1_2.Add(self.SetSessionWindowTitle) sizer_1_1_3 = wx.FlexGridSizer(1, 2, 7, 9) @@ -452,8 +452,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog): sizer_1_2_1.Add(self.RDPOptions, pos=(5,2), ) sizer_1_2.Add(sizer_1_2_1, flag=wx.EXPAND|wx.ALL, border=7) - sizer_1.Add(sizer_1_1, 1, flag=wx.EXPAND|wx.ALL, border=5) - sizer_1.Add(sizer_1_2, 1, flag=wx.EXPAND|wx.ALL, border=5) + sizer_1.Add(sizer_1_1, flag=wx.EXPAND|wx.ALL, border=5) + sizer_1.Add(sizer_1_2, proportion=1, flag=wx.EXPAND|wx.ALL, border=5) self.tab_Session.SetSizerAndFit(sizer_1) self.tab_Session.Layout() @@ -702,9 +702,9 @@ class PyHocaGUI_ProfileManager(wx.Dialog): max2_x, max2_y = self.tab_Connection.GetBestSize() max3_x, max3_y = self.tab_Settings.GetBestSize() max4_x, max4_y = self.tab_SharedFilesAndFolders.GetBestSize() - sizer_B_x, sizer_B_y = sizer_B.GetSize() - self.SetSize((max(max1_x, max2_x, max3_x, max4_x) * 1.05, (max(max1_y, max2_y, max3_y, max4_y) + sizer_B_y) * 1.2)) + self.SetSize(self.GetBestSize()) + self.SetSize((max(max1_x, max2_x, max3_x, max4_x) * 1.05, max(max1_y, max2_y, max3_y, max4_y) + 64)) self.SetAutoLayout(True) self.Layout() self.CentreOnScreen() @@ -979,8 +979,8 @@ class PyHocaGUI_ProfileManager(wx.Dialog): self.staticbox_Profile.Enable(False) self.ProfileNameLabel.Enable(False) self.ProfileName.Enable(False) - self.IconButton.Enable(False) - self.IconButtonLabel.Enable(False) + #self.IconButton.Enable(False) + #self.IconButtonLabel.Enable(False) self.HostLabel.Enable(False) self.Host.Enable(False) self.UserNameLabel.Enable(False) @@ -1010,7 +1010,7 @@ class PyHocaGUI_ProfileManager(wx.Dialog): self.profile_config['name'] = self.ProfileName.GetValue() self.profile_config['setsessiontitle'] = self.SetSessionWindowTitle.GetValue() self.profile_config['sessiontitle'] = self.SessionWindowTitle.GetValue() - self.profile_config['icon'] = self.IconPath + #self.profile_config['icon'] = self.IconPath self.profile_config['user'] = self.UserName.GetValue() self.profile_config['key'] = self.SSHKeyFile.GetValue() if self.UseSSHProxy.GetValue(): @@ -1116,25 +1116,25 @@ class PyHocaGUI_ProfileManager(wx.Dialog): _mimebox_action = 'OPEN' self.profile_config['mimeboxaction'] = _mimebox_action - def OnIconChange(self, event): - _share_location = os.path.split(_icons_location)[0] - iconsdir = _icons_location - if not os.path.exists(iconsdir): - iconsdir = os.getcwd() - wildcard = _(u"Icon Files (*.png)|*.png|" \ - "All files (*.*)|*") - dlg = wx.FileDialog( - self, message=_(u"Choose an icon for this session profile"), defaultDir=iconsdir, - defaultFile="", wildcard=wildcard, style=wx.OPEN | wx.CHANGE_DIR ) - # 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. - path_to_icon = dlg.GetPath() - self.IconButton.SetBitmapLabel(wx.Bitmap(path_to_icon, wx.BITMAP_TYPE_ANY)) - rel_path = path_to_icon.replace('%s/' % _share_location, ':') - rel_path = rel_path.replace( 'icons/PyHoca/128x128/pyhoca-session.png', 'icons/128x128/x2gosession.png') - self.IconPath = rel_path + #def OnIconChange(self, event): + # _share_location = os.path.split(_icons_location)[0] + # iconsdir = _icons_location + # if not os.path.exists(iconsdir): + # iconsdir = os.getcwd() + # wildcard = _(u"Icon Files (*.png)|*.png|" \ + # "All files (*.*)|*") + # dlg = wx.FileDialog( + # self, message=_(u"Choose an icon for this session profile"), defaultDir=iconsdir, + # defaultFile="", wildcard=wildcard, style=wx.OPEN | wx.CHANGE_DIR ) + # # 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. + # path_to_icon = dlg.GetPath() + # self.IconButton.SetBitmapLabel(wx.Bitmap(path_to_icon, wx.BITMAP_TYPE_ANY)) + # rel_path = path_to_icon.replace('%s/' % _share_location, ':') + # rel_path = rel_path.replace( 'icons/PyHoca/128x128/pyhoca-session.png', 'icons/128x128/x2gosession.png') + # self.IconPath = rel_path def OnSetSessionWindowTitle(self, event): if self.SetSessionWindowTitle.GetValue(): 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)).