def _position(self, card): OpenStack._position(self, card) # if TOOLKIT == 'tk': rows = [s for s in self.game.s.rows[:self.id] if s.cards] if rows: self.group.tkraise(rows[-1].group) return rows = [s for s in self.game.s.rows[self.id + 1:] if s.cards] if rows: self.group.lower(rows[0].group) return elif TOOLKIT == 'kivy': rows = [s for s in self.game.s.rows[:self.id] if s.cards] if rows: # self.group.tkraise(rows[-1].group) return rows = [s for s in self.game.s.rows[self.id + 1:] if s.cards] if rows: # self.group.lower(rows[0].group) return elif TOOLKIT == 'gtk': # FIXME (this is very slow) for s in self.game.s.rows[self.id + 1:]: s.group.tkraise()
def _position(self, card): OpenStack._position(self, card) # if TOOLKIT == 'tk': rows = [s for s in self.game.s.rows[:self.id] if s.cards] if rows: self.group.tkraise(rows[-1].group) return rows = [s for s in self.game.s.rows[self.id+1:] if s.cards] if rows: self.group.lower(rows[0].group) return elif TOOLKIT == 'kivy': rows = [s for s in self.game.s.rows[:self.id] if s.cards] if rows: # self.group.tkraise(rows[-1].group) return rows = [s for s in self.game.s.rows[self.id+1:] if s.cards] if rows: # self.group.lower(rows[0].group) return elif TOOLKIT == 'gtk': # FIXME (this is very slow) for s in self.game.s.rows[self.id+1:]: s.group.tkraise()
def _position(self, card): # AbstractFoundationStack._position(self, card) OpenStack._position(self, card) fnds = self.game.s.foundations cols = (3, 2, 1, 0) for i in cols: for j in range(9): n = i * 9 + j if fnds[n].cards: fnds[n].group.tkraise() return
def _position(self, card): # AbstractFoundationStack._position(self, card) OpenStack._position(self, card) fnds = self.game.s.foundations cols = (3, 2, 1, 0) for i in cols: for j in range(9): n = i*9+j if fnds[n].cards: fnds[n].group.tkraise() return