mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 02:03:11 +02:00
rename NodeList ownerUUID to sessionUUID
This commit is contained in:
parent
f02e1aaf47
commit
e72f6d16cc
7 changed files with 17 additions and 17 deletions
|
@ -131,7 +131,7 @@ void AssignmentClient::readPendingDatagrams() {
|
||||||
// switch our nodelist domain IP and port to whoever sent us the assignment
|
// switch our nodelist domain IP and port to whoever sent us the assignment
|
||||||
|
|
||||||
nodeList->setDomainSockAddr(senderSockAddr);
|
nodeList->setDomainSockAddr(senderSockAddr);
|
||||||
nodeList->setOwnerUUID(_currentAssignment->getUUID());
|
nodeList->setSessionUUID(_currentAssignment->getUUID());
|
||||||
|
|
||||||
qDebug() << "Destination IP for assignment is" << nodeList->getDomainIP().toString();
|
qDebug() << "Destination IP for assignment is" << nodeList->getDomainIP().toString();
|
||||||
|
|
||||||
|
|
|
@ -3850,7 +3850,7 @@ void Application::updateWindowTitle(){
|
||||||
QString buildVersion = " (build " + applicationVersion() + ")";
|
QString buildVersion = " (build " + applicationVersion() + ")";
|
||||||
NodeList* nodeList = NodeList::getInstance();
|
NodeList* nodeList = NodeList::getInstance();
|
||||||
|
|
||||||
QString title = QString() + _profile.getUsername() + " " + nodeList->getOwnerUUID().toString()
|
QString title = QString() + _profile.getUsername() + " " + nodeList->getSessionUUID().toString()
|
||||||
+ " @ " + nodeList->getDomainHostname() + buildVersion;
|
+ " @ " + nodeList->getDomainHostname() + buildVersion;
|
||||||
|
|
||||||
qDebug("Application title set to: %s", title.toStdString().c_str());
|
qDebug("Application title set to: %s", title.toStdString().c_str());
|
||||||
|
|
|
@ -73,7 +73,7 @@ class AvatarData : public NodeData {
|
||||||
|
|
||||||
Q_PROPERTY(glm::quat orientation READ getOrientation WRITE setOrientation)
|
Q_PROPERTY(glm::quat orientation READ getOrientation WRITE setOrientation)
|
||||||
Q_PROPERTY(float headPitch READ getHeadPitch WRITE setHeadPitch)
|
Q_PROPERTY(float headPitch READ getHeadPitch WRITE setHeadPitch)
|
||||||
|
|
||||||
public:
|
public:
|
||||||
AvatarData();
|
AvatarData();
|
||||||
~AvatarData();
|
~AvatarData();
|
||||||
|
|
|
@ -17,5 +17,5 @@ DataServerScriptingInterface::DataServerScriptingInterface()
|
||||||
}
|
}
|
||||||
|
|
||||||
void DataServerScriptingInterface::setValueForKey(const QString& key, const QString& value) {
|
void DataServerScriptingInterface::setValueForKey(const QString& key, const QString& value) {
|
||||||
DataServerClient::putValueForKeyAndUUID(key, value, NodeList::getInstance()->getOwnerUUID());
|
DataServerClient::putValueForKeyAndUUID(key, value, NodeList::getInstance()->getSessionUUID());
|
||||||
}
|
}
|
|
@ -64,7 +64,7 @@ NodeList::NodeList(char newOwnerType, unsigned short int newSocketListenPort) :
|
||||||
_nodeSocket(this),
|
_nodeSocket(this),
|
||||||
_ownerType(newOwnerType),
|
_ownerType(newOwnerType),
|
||||||
_nodeTypesOfInterest(),
|
_nodeTypesOfInterest(),
|
||||||
_ownerUUID(),
|
_sessionUUID(),
|
||||||
_numNoReplyDomainCheckIns(0),
|
_numNoReplyDomainCheckIns(0),
|
||||||
_assignmentServerSocket(),
|
_assignmentServerSocket(),
|
||||||
_publicSockAddr(),
|
_publicSockAddr(),
|
||||||
|
@ -257,7 +257,7 @@ void NodeList::reset() {
|
||||||
_nodeTypesOfInterest.clear();
|
_nodeTypesOfInterest.clear();
|
||||||
|
|
||||||
// refresh the owner UUID
|
// refresh the owner UUID
|
||||||
_ownerUUID = QUuid::createUuid();
|
_sessionUUID = QUuid::createUuid();
|
||||||
}
|
}
|
||||||
|
|
||||||
void NodeList::addNodeTypeToInterestSet(NodeType_t nodeTypeToAdd) {
|
void NodeList::addNodeTypeToInterestSet(NodeType_t nodeTypeToAdd) {
|
||||||
|
@ -492,13 +492,13 @@ void NodeList::sendDomainServerCheckIn() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void NodeList::setOwnerUUID(const QUuid& ownerUUID) {
|
void NodeList::setSessionUUID(const QUuid& sessionUUID) {
|
||||||
QUuid oldUUID = _ownerUUID;
|
QUuid oldUUID = _sessionUUID;
|
||||||
_ownerUUID = ownerUUID;
|
_sessionUUID = sessionUUID;
|
||||||
|
|
||||||
if (ownerUUID != oldUUID) {
|
if (sessionUUID != oldUUID) {
|
||||||
qDebug() << "NodeList UUID changed from" << oldUUID << "to" << _ownerUUID;
|
qDebug() << "NodeList UUID changed from" << oldUUID << "to" << _sessionUUID;
|
||||||
emit uuidChanged(ownerUUID);
|
emit uuidChanged(sessionUUID);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -522,7 +522,7 @@ int NodeList::processDomainServerList(const QByteArray& packet) {
|
||||||
// pull our owner UUID from the packet, it's always the first thing
|
// pull our owner UUID from the packet, it's always the first thing
|
||||||
QUuid newUUID;
|
QUuid newUUID;
|
||||||
packetStream >> newUUID;
|
packetStream >> newUUID;
|
||||||
setOwnerUUID(newUUID);
|
setSessionUUID(newUUID);
|
||||||
|
|
||||||
// pull each node in the packet
|
// pull each node in the packet
|
||||||
while(packetStream.device()->pos() < packet.size()) {
|
while(packetStream.device()->pos() < packet.size()) {
|
||||||
|
|
|
@ -72,8 +72,8 @@ public:
|
||||||
|
|
||||||
unsigned short getDomainPort() const { return _domainSockAddr.getPort(); }
|
unsigned short getDomainPort() const { return _domainSockAddr.getPort(); }
|
||||||
|
|
||||||
const QUuid& getOwnerUUID() const { return _ownerUUID; }
|
const QUuid& getSessionUUID() const { return _sessionUUID; }
|
||||||
void setOwnerUUID(const QUuid& ownerUUID);
|
void setSessionUUID(const QUuid& sessionUUID);
|
||||||
|
|
||||||
QUdpSocket& getNodeSocket() { return _nodeSocket; }
|
QUdpSocket& getNodeSocket() { return _nodeSocket; }
|
||||||
|
|
||||||
|
@ -146,7 +146,7 @@ private:
|
||||||
QUdpSocket _nodeSocket;
|
QUdpSocket _nodeSocket;
|
||||||
NodeType_t _ownerType;
|
NodeType_t _ownerType;
|
||||||
NodeSet _nodeTypesOfInterest;
|
NodeSet _nodeTypesOfInterest;
|
||||||
QUuid _ownerUUID;
|
QUuid _sessionUUID;
|
||||||
int _numNoReplyDomainCheckIns;
|
int _numNoReplyDomainCheckIns;
|
||||||
HifiSockAddr _assignmentServerSocket;
|
HifiSockAddr _assignmentServerSocket;
|
||||||
HifiSockAddr _publicSockAddr;
|
HifiSockAddr _publicSockAddr;
|
||||||
|
|
|
@ -69,7 +69,7 @@ int populatePacketHeader(char* packet, PacketType type, const QUuid& connectionU
|
||||||
int numTypeBytes = packArithmeticallyCodedValue(type, packet);
|
int numTypeBytes = packArithmeticallyCodedValue(type, packet);
|
||||||
packet[numTypeBytes] = versionForPacketType(type);
|
packet[numTypeBytes] = versionForPacketType(type);
|
||||||
|
|
||||||
QUuid packUUID = connectionUUID.isNull() ? NodeList::getInstance()->getOwnerUUID() : connectionUUID;
|
QUuid packUUID = connectionUUID.isNull() ? NodeList::getInstance()->getSessionUUID() : connectionUUID;
|
||||||
|
|
||||||
QByteArray rfcUUID = packUUID.toRfc4122();
|
QByteArray rfcUUID = packUUID.toRfc4122();
|
||||||
memcpy(packet + numTypeBytes + sizeof(PacketVersion), rfcUUID.constData(), NUM_BYTES_RFC4122_UUID);
|
memcpy(packet + numTypeBytes + sizeof(PacketVersion), rfcUUID.constData(), NUM_BYTES_RFC4122_UUID);
|
||||||
|
|
Loading…
Reference in a new issue