diff browser_side/panels.py @ 37:b306aa090438

Tarot game: game launching (first hand showed), and contract selection
author Goffi <goffi@goffi.org>
date Wed, 18 May 2011 01:45:28 +0200
parents 1d406077b49b
children 7bea2ae0c4fb
line wrap: on
line diff
--- a/browser_side/panels.py	Tue May 17 01:33:12 2011 +0200
+++ b/browser_side/panels.py	Wed May 18 01:45:28 2011 +0200
@@ -24,7 +24,6 @@
 from pyjamas.ui.FlowPanel import FlowPanel
 from pyjamas.ui.AbsolutePanel import AbsolutePanel
 from pyjamas.ui.VerticalPanel import VerticalPanel
-from pyjamas.ui.DockPanel import DockPanel
 from pyjamas.ui.HorizontalPanel import HorizontalPanel
 from pyjamas.ui.ScrollPanel import ScrollPanel
 from pyjamas.ui.TabPanel import TabPanel
@@ -563,6 +562,12 @@
             self.tarot_panel = CardPanel(self, referee, players, self.nick)
             self.vpanel.insert(self.tarot_panel, 1)
             self.vpanel.setCellHeight(self.tarot_panel, self.tarot_panel.getHeight())
+    
+    def getGame(self, game_type):
+        """Return class managing the game type"""
+        #TODO: check that the game is launched, and manage errors
+        if game_type=="Tarot":
+            return self.tarot_panel 
 
 class MainDiscussionPanel(HorizontalPanel):