Mercurial > libervia-backend
comparison frontends/src/wix/main_window.py @ 679:59c9a7ff903d
wix, misc: use picture of dimension 32x32 for tray icon + better PEP-8 compliance
author | souliane <souliane@mailoo.org> |
---|---|
date | Tue, 22 Oct 2013 09:41:27 +0200 |
parents | e2eff3c7ad02 |
children | f7878ad3c846 |
comparison
equal
deleted
inserted
replaced
678:a630b94280d5 | 679:59c9a7ff903d |
---|---|
70 self.chat_wins=ChatList(self) | 70 self.chat_wins=ChatList(self) |
71 self.CreateStatusBar() | 71 self.CreateStatusBar() |
72 | 72 |
73 #ToolBar | 73 #ToolBar |
74 self.tools=self.CreateToolBar() | 74 self.tools=self.CreateToolBar() |
75 self.statusBox = wx.ComboBox(self.tools, -1, "Online", choices=[status[1] for status in const_STATUS], | 75 self.statusBox = wx.ComboBox(self.tools, -1, "Online", choices=[status[1] for status in const_STATUS], |
76 style=wx.CB_DROPDOWN | wx.CB_READONLY) | 76 style=wx.CB_DROPDOWN | wx.CB_READONLY) |
77 self.tools.AddControl(self.statusBox) | 77 self.tools.AddControl(self.statusBox) |
78 self.tools.AddSeparator() | 78 self.tools.AddSeparator() |
79 self.statusTxt=wx.TextCtrl(self.tools, -1, style = wx.TE_PROCESS_ENTER) | 79 self.statusTxt=wx.TextCtrl(self.tools, -1, style = wx.TE_PROCESS_ENTER) |
80 self.tools.AddControl(self.statusTxt) | 80 self.tools.AddControl(self.statusTxt) |
81 self.Bind(wx.EVT_COMBOBOX, self.onStatusChange, self.statusBox) | 81 self.Bind(wx.EVT_COMBOBOX, self.onStatusChange, self.statusBox) |
82 self.Bind(wx.EVT_TEXT_ENTER, self.onStatusChange, self.statusTxt) | 82 self.Bind(wx.EVT_TEXT_ENTER, self.onStatusChange, self.statusTxt) |
83 self.tools.Disable() | 83 self.tools.Disable() |
84 | 84 |
85 | |
86 | |
87 #tray icon | 85 #tray icon |
88 ticon = wx.Icon(os.path.join(self.media_dir, 'icons/crystal/tray_icon.xpm'), wx.BITMAP_TYPE_XPM) | 86 ticon = wx.Icon(os.path.join(self.media_dir, 'icons/crystal/32/tray_icon.xpm'), wx.BITMAP_TYPE_XPM) |
89 self.tray_icon = wx.TaskBarIcon() | 87 self.tray_icon = wx.TaskBarIcon() |
90 self.tray_icon.SetIcon(ticon, _("Wix jabber client")) | 88 self.tray_icon.SetIcon(ticon, _("Wix jabber client")) |
91 wx.EVT_TASKBAR_LEFT_UP(self.tray_icon, self.onTrayClick) | 89 wx.EVT_TASKBAR_LEFT_UP(self.tray_icon, self.onTrayClick) |
92 | 90 |
93 | 91 |