# HG changeset patch # User Goffi # Date 1308494144 -7200 # Node ID d57e0d6b1ced229e496f89567e255f83561bb153 # Parent 12680e220b35e6d2f4476c4242f6295a697d9c11 browser side: inclusion of Adrien's icons diff -r 12680e220b35 -r d57e0d6b1ced browser_side/menu.py --- a/browser_side/menu.py Sun Jun 19 01:33:29 2011 +0200 +++ b/browser_side/menu.py Sun Jun 19 16:35:44 2011 +0200 @@ -69,6 +69,7 @@ self.host = host SimplePanel.__init__(self) self.setStyleName('menuContainer') + _item_tpl = "%s" menu_general = MenuBar(vertical=True) menu_general.addItem("Social contract", MenuCmd(self, "onSocialContract")) @@ -86,14 +87,26 @@ menu_games.addItem("Tarot", MenuCmd(self, "onTarotGame")) menu_games.addItem("Xiangqi", MenuCmd(self, "onXiangqiGame")) + menu_help = MenuBar(vertical=True) + + menu_settings = MenuBar(vertical=True) + menubar = LiberviaMenuBar() - menubar.addItem(MenuItem("General", menu_general)) - menubar.addItem(MenuItem("Contacts", menu_contacts)) - menubar.addItem(MenuItem("Groups", menu_group)) + + for _name, _icon, _menu in [('General', 'home', menu_general), + ('Contacts', 'social', menu_contacts), + ('Groups', 'social', menu_group), + ('Games', 'games', menu_games)]: + menubar.addItem(MenuItem(_item_tpl % (_icon, _name), True, _menu)) + _separator = MenuItem('', None) _separator.setStyleName('menuSeparator') menubar.addItem(_separator, None) - menubar.addItem(MenuItem("Games", True, menu_games)) + + for _name, _icon, _menu in [('Help', 'help', menu_help), + ('Settings', 'settings', menu_settings)]: + menubar.addItem(MenuItem(_item_tpl % (_icon, _name), True, _menu)) + self.add(menubar) #General menu diff -r 12680e220b35 -r d57e0d6b1ced public/libervia.css --- a/public/libervia.css Sun Jun 19 01:33:29 2011 +0200 +++ b/public/libervia.css Sun Jun 19 16:35:44 2011 +0200 @@ -143,6 +143,10 @@ -o-transition: color 0.2s linear; } +.gwt-MenuItem img { + padding-right: 2px; +} + .gwt-MenuBar-horizontal .gwt-MenuItem-selected { filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=’#eee’, endColorstr=’#aaa′); background: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#aaa));