MCPcopy Create free account
hub / github.com/Syncplay/syncplay / areAllRelevantUsersInRoomReady

Method areAllRelevantUsersInRoomReady

syncplay/client.py:1511–1530  ·  view source on GitHub ↗
(self, requireSameFilenames=False)

Source from the content-addressed store, hash-verified

1509 user.setControllerStatus(True)
1510
1511 def areAllRelevantUsersInRoomReady(self, requireSameFilenames=False):
1512 if not self.currentUser.isReady():
1513 return False
1514 if self.currentUser.canControl():
1515 return self.areAllUsersInRoomReady(requireSameFilenames)
1516 else:
1517 for user in self._users.values():
1518 if user.room == self.currentUser.room and user.canControl():
1519 if user.isReadyWithFile() == False:
1520 return False
1521 elif (
1522 requireSameFilenames and
1523 (
1524 self.currentUser.file is None
1525 or user.file is None
1526 or not utils.sameFilename(self.currentUser.file['name'], user.file['name'])
1527 )
1528 ):
1529 return False
1530 return True
1531
1532 def areAllUsersInRoomReady(self, requireSameFilenames=False):
1533 if not self.currentUser.isReady():

Callers 1

checkReadyStatesMethod · 0.80

Calls 4

isReadyMethod · 0.45
canControlMethod · 0.45
isReadyWithFileMethod · 0.45

Tested by

no test coverage detected