Swap game_playable to use the simplified disable ability

This commit is contained in:
Dave Pearson
2023-02-14 14:59:53 +00:00
parent 5e0190c43f
commit e26e75a9d1

View File

@@ -194,8 +194,7 @@ class Game(Screen):
Args: Args:
playable (bool): Should the game currently be playable? playable (bool): Should the game currently be playable?
""" """
for cell in self.query(GameCell): self.query_one(GameGrid).disabled = not playable
cell.disabled = not playable
def cell(self, row: int, col: int) -> GameCell: def cell(self, row: int, col: int) -> GameCell:
"""Get the cell at a given location. """Get the cell at a given location.