Mercurial > libervia-backend
comparison frontends/primitivus/primitivus @ 144:80661755ea8d
Primitivus: Tarot card game implementation
- quick frontend: card_game added
- wix: card_game splitted with quick frontend
- tools: new game library
- primitivus: new card_game widget (not finished yet)
- primitivus: SàT XML UI management: first draft
author | Goffi <goffi@goffi.org> |
---|---|
date | Mon, 26 Jul 2010 19:43:44 +0800 |
parents | 227394eb080c |
children | c8b231abfe96 |
comparison
equal
deleted
inserted
replaced
143:119f45746fde | 144:80661755ea8d |
---|---|
67 ('other_nick', 'dark cyan,bold', 'default'), | 67 ('other_nick', 'dark cyan,bold', 'default'), |
68 ('menubar', 'light gray,bold', 'dark red'), | 68 ('menubar', 'light gray,bold', 'dark red'), |
69 ('selected_menu', 'light gray,bold', 'dark green'), | 69 ('selected_menu', 'light gray,bold', 'dark green'), |
70 ('menuitem', 'light gray,bold', 'dark red'), | 70 ('menuitem', 'light gray,bold', 'dark red'), |
71 ('menuitem_focus', 'light gray,bold', 'dark green'), | 71 ('menuitem_focus', 'light gray,bold', 'dark green'), |
72 ('card_neutral', 'dark gray', 'white', 'standout,underline'), | |
73 ('card_neutral_selected', 'dark gray', 'dark green', 'standout,underline'), | |
74 ('card_special', 'brown', 'white', 'standout,underline'), | |
75 ('card_special_selected', 'brown', 'dark green', 'standout,underline'), | |
76 ('card_red', 'dark red', 'white', 'standout,underline'), | |
77 ('card_red_selected', 'dark red', 'dark green', 'standout,underline'), | |
78 ('card_black', 'black', 'white', 'standout,underline'), | |
79 ('card_black_selected', 'black', 'dark green', 'standout,underline'), | |
72 ] | 80 ] |
73 | 81 |
74 class ChatList(QuickChatList): | 82 class ChatList(QuickChatList): |
75 """This class manage the list of chat windows""" | 83 """This class manage the list of chat windows""" |
76 | 84 |
203 def contactSelected(self, contact_list): | 211 def contactSelected(self, contact_list): |
204 contact = contact_list.get_contact() | 212 contact = contact_list.get_contact() |
205 if contact: | 213 if contact: |
206 assert(len(self.center_part.widget_list)==2) | 214 assert(len(self.center_part.widget_list)==2) |
207 self.center_part.widget_list[1] = self.chat_wins[contact] | 215 self.center_part.widget_list[1] = self.chat_wins[contact] |
208 self.menu_roller.addMenu(_('Chat Menu'), self.chat_wins[contact].getMenu()) | 216 self.menu_roller.addMenu(_('Chat menu'), self.chat_wins[contact].getMenu()) |
209 | 217 |
210 def onTextEntered(self, editBar): | 218 def onTextEntered(self, editBar): |
211 """Called when text is entered in the main edit bar""" | 219 """Called when text is entered in the main edit bar""" |
212 contact = self.contactList.get_contact() ###Based on the fact that there is currently only one contact selectableat once | 220 contact = self.contactList.get_contact() ###Based on the fact that there is currently only one contact selectableat once |
213 if contact: | 221 if contact: |