예제 #1
0
 def saveGame(self, game, position=None):
     if not game.isChanged():
         return
     if game.uri and isWriteable(game.uri):
         self.saveGameSimple(game.uri, game, position=position)
     else:
         return self.saveGameAs(game, position=position)
예제 #2
0
def saveGame(game):
    if not game.isChanged():
        return
    if game.uri and isWriteable(game.uri):
        saveGameSimple(game.uri, game)
    else:
        return saveGameAs(game)
예제 #3
0
 def saveGame(self, game, position=None):
     if not game.isChanged():
         return
     if game.uri and isWriteable(game.uri):
         self.saveGameSimple(game.uri, game, position=position)
     else:
         return self.saveGameAs(game, position=position)
예제 #4
0
파일: ionest.py 프로젝트: Krando/pychess
def saveGame (game):
    if not game.isChanged():
        return
    if game.uri and isWriteable (game.uri):
        saveGameSimple (game.uri, game)
    else:
        return saveGameAs (game)
예제 #5
0
 def isChanged(self):
     if self.ply == 0:
         return False
     if self.needsSave:
         return True
     if not self.uri or not isWriteable(self.uri):
         return True
     return False
예제 #6
0
파일: GameModel.py 프로젝트: JKrame/pychess
 def isChanged(self):
     if self.ply == 0:
         return False
     if self.needsSave:
         return True
     if not self.uri or not isWriteable(self.uri):
         return True
     return False