mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 06:18:52 +02:00
Merge pull request #12288 from ctrlaltdavid/21729
Add location.domainID as a synonym for location.domainId
This commit is contained in:
commit
f5614618b9
5 changed files with 18 additions and 15 deletions
|
@ -453,7 +453,7 @@ void EntityServer::domainSettingsRequestFailed() {
|
||||||
void EntityServer::startDynamicDomainVerification() {
|
void EntityServer::startDynamicDomainVerification() {
|
||||||
qCDebug(entities) << "Starting Dynamic Domain Verification...";
|
qCDebug(entities) << "Starting Dynamic Domain Verification...";
|
||||||
|
|
||||||
QString thisDomainID = DependencyManager::get<AddressManager>()->getDomainId().remove(QRegExp("\\{|\\}"));
|
QString thisDomainID = DependencyManager::get<AddressManager>()->getDomainID().remove(QRegExp("\\{|\\}"));
|
||||||
|
|
||||||
EntityTreePointer tree = std::static_pointer_cast<EntityTree>(_tree);
|
EntityTreePointer tree = std::static_pointer_cast<EntityTree>(_tree);
|
||||||
QHash<QString, EntityItemID> localMap(tree->getEntityCertificateIDMap());
|
QHash<QString, EntityItemID> localMap(tree->getEntityCertificateIDMap());
|
||||||
|
|
|
@ -776,7 +776,7 @@ void AddressManager::copyPath() {
|
||||||
QApplication::clipboard()->setText(currentPath());
|
QApplication::clipboard()->setText(currentPath());
|
||||||
}
|
}
|
||||||
|
|
||||||
QString AddressManager::getDomainId() const {
|
QString AddressManager::getDomainID() const {
|
||||||
return DependencyManager::get<NodeList>()->getDomainHandler().getUUID().toString();
|
return DependencyManager::get<NodeList>()->getDomainHandler().getUUID().toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -35,9 +35,11 @@ const QString GET_PLACE = "/api/v1/places/%1";
|
||||||
* The location API provides facilities related to your current location in the metaverse.
|
* The location API provides facilities related to your current location in the metaverse.
|
||||||
*
|
*
|
||||||
* @namespace location
|
* @namespace location
|
||||||
* @property {Uuid} domainId - A UUID uniquely identifying the domain you're visiting. Is {@link Uuid|Uuid.NULL} if you're not
|
* @property {Uuid} domainID - A UUID uniquely identifying the domain you're visiting. Is {@link Uuid|Uuid.NULL} if you're not
|
||||||
* connected to the domain.
|
* connected to the domain.
|
||||||
* <em>Read-only.</em>
|
* <em>Read-only.</em>
|
||||||
|
* @property {Uuid} domainId - Synonym for <code>domainId</code>. <em>Read-only.</em> <strong>Deprecated:</strong> This property
|
||||||
|
* is deprecated and will soon be removed.
|
||||||
* @property {string} hostname - The name of the domain for your current metaverse address (e.g., <code>"AvatarIsland"</code>,
|
* @property {string} hostname - The name of the domain for your current metaverse address (e.g., <code>"AvatarIsland"</code>,
|
||||||
* <code>localhost</code>, or an IP address).
|
* <code>localhost</code>, or an IP address).
|
||||||
* <em>Read-only.</em>
|
* <em>Read-only.</em>
|
||||||
|
@ -66,7 +68,8 @@ class AddressManager : public QObject, public Dependency {
|
||||||
Q_PROPERTY(QString hostname READ getHost)
|
Q_PROPERTY(QString hostname READ getHost)
|
||||||
Q_PROPERTY(QString pathname READ currentPath)
|
Q_PROPERTY(QString pathname READ currentPath)
|
||||||
Q_PROPERTY(QString placename READ getPlaceName)
|
Q_PROPERTY(QString placename READ getPlaceName)
|
||||||
Q_PROPERTY(QString domainId READ getDomainId)
|
Q_PROPERTY(QString domainID READ getDomainID)
|
||||||
|
Q_PROPERTY(QString domainId READ getDomainID)
|
||||||
public:
|
public:
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
|
@ -164,7 +167,7 @@ public:
|
||||||
|
|
||||||
const QUuid& getRootPlaceID() const { return _rootPlaceID; }
|
const QUuid& getRootPlaceID() const { return _rootPlaceID; }
|
||||||
const QString& getPlaceName() const { return _shareablePlaceName.isEmpty() ? _placeName : _shareablePlaceName; }
|
const QString& getPlaceName() const { return _shareablePlaceName.isEmpty() ? _placeName : _shareablePlaceName; }
|
||||||
QString getDomainId() const;
|
QString getDomainID() const;
|
||||||
|
|
||||||
const QString& getHost() const { return _host; }
|
const QString& getHost() const { return _host; }
|
||||||
|
|
||||||
|
|
|
@ -493,7 +493,7 @@ function populateNearbyUserList(selectData, oldAudioData) {
|
||||||
data.push(avatarPalDatum);
|
data.push(avatarPalDatum);
|
||||||
print('PAL data:', JSON.stringify(avatarPalDatum));
|
print('PAL data:', JSON.stringify(avatarPalDatum));
|
||||||
});
|
});
|
||||||
getConnectionData(false, location.domainId); // Even admins don't get relationship data in requestUsernameFromID (which is still needed for admin status, which comes from domain).
|
getConnectionData(false, location.domainID); // Even admins don't get relationship data in requestUsernameFromID (which is still needed for admin status, which comes from domain).
|
||||||
conserveResources = Object.keys(avatarsOfInterest).length > 20;
|
conserveResources = Object.keys(avatarsOfInterest).length > 20;
|
||||||
sendToQml({ method: 'nearbyUsers', params: data });
|
sendToQml({ method: 'nearbyUsers', params: data });
|
||||||
if (selectData) {
|
if (selectData) {
|
||||||
|
|
|
@ -337,7 +337,7 @@ function fillImageDataFromPrevious() {
|
||||||
containsGif: previousAnimatedSnapPath !== "",
|
containsGif: previousAnimatedSnapPath !== "",
|
||||||
processingGif: false,
|
processingGif: false,
|
||||||
shouldUpload: false,
|
shouldUpload: false,
|
||||||
canBlast: location.domainId === Settings.getValue("previousSnapshotDomainID"),
|
canBlast: location.domainID === Settings.getValue("previousSnapshotDomainID"),
|
||||||
isLoggedIn: isLoggedIn
|
isLoggedIn: isLoggedIn
|
||||||
};
|
};
|
||||||
imageData = [];
|
imageData = [];
|
||||||
|
@ -416,7 +416,7 @@ function snapshotUploaded(isError, reply) {
|
||||||
}
|
}
|
||||||
isUploadingPrintableStill = false;
|
isUploadingPrintableStill = false;
|
||||||
}
|
}
|
||||||
var href, domainId;
|
var href, domainID;
|
||||||
function takeSnapshot() {
|
function takeSnapshot() {
|
||||||
tablet.emitScriptEvent(JSON.stringify({
|
tablet.emitScriptEvent(JSON.stringify({
|
||||||
type: "snapshot",
|
type: "snapshot",
|
||||||
|
@ -443,11 +443,11 @@ function takeSnapshot() {
|
||||||
MyAvatar.setClearOverlayWhenMoving(false);
|
MyAvatar.setClearOverlayWhenMoving(false);
|
||||||
|
|
||||||
// We will record snapshots based on the starting location. That could change, e.g., when recording a .gif.
|
// We will record snapshots based on the starting location. That could change, e.g., when recording a .gif.
|
||||||
// Even the domainId could change (e.g., if the user falls into a teleporter while recording).
|
// Even the domainID could change (e.g., if the user falls into a teleporter while recording).
|
||||||
href = location.href;
|
href = location.href;
|
||||||
Settings.setValue("previousSnapshotHref", href);
|
Settings.setValue("previousSnapshotHref", href);
|
||||||
domainId = location.domainId;
|
domainID = location.domainID;
|
||||||
Settings.setValue("previousSnapshotDomainID", domainId);
|
Settings.setValue("previousSnapshotDomainID", domainID);
|
||||||
|
|
||||||
maybeDeleteSnapshotStories();
|
maybeDeleteSnapshotStories();
|
||||||
|
|
||||||
|
@ -548,7 +548,7 @@ function stillSnapshotTaken(pathStillSnapshot, notify) {
|
||||||
}
|
}
|
||||||
HMD.openTablet();
|
HMD.openTablet();
|
||||||
|
|
||||||
isDomainOpen(domainId, function (canShare) {
|
isDomainOpen(domainID, function (canShare) {
|
||||||
snapshotOptions = {
|
snapshotOptions = {
|
||||||
containsGif: false,
|
containsGif: false,
|
||||||
processingGif: false,
|
processingGif: false,
|
||||||
|
@ -594,7 +594,7 @@ function processingGifStarted(pathStillSnapshot) {
|
||||||
}
|
}
|
||||||
HMD.openTablet();
|
HMD.openTablet();
|
||||||
|
|
||||||
isDomainOpen(domainId, function (canShare) {
|
isDomainOpen(domainID, function (canShare) {
|
||||||
snapshotOptions = {
|
snapshotOptions = {
|
||||||
containsGif: true,
|
containsGif: true,
|
||||||
processingGif: true,
|
processingGif: true,
|
||||||
|
@ -622,13 +622,13 @@ function processingGifCompleted(pathAnimatedSnapshot) {
|
||||||
|
|
||||||
Settings.setValue("previousAnimatedSnapPath", pathAnimatedSnapshot);
|
Settings.setValue("previousAnimatedSnapPath", pathAnimatedSnapshot);
|
||||||
|
|
||||||
isDomainOpen(domainId, function (canShare) {
|
isDomainOpen(domainID, function (canShare) {
|
||||||
snapshotOptions = {
|
snapshotOptions = {
|
||||||
containsGif: true,
|
containsGif: true,
|
||||||
processingGif: false,
|
processingGif: false,
|
||||||
canShare: canShare,
|
canShare: canShare,
|
||||||
isLoggedIn: isLoggedIn,
|
isLoggedIn: isLoggedIn,
|
||||||
canBlast: location.domainId === Settings.getValue("previousSnapshotDomainID"),
|
canBlast: location.domainID === Settings.getValue("previousSnapshotDomainID"),
|
||||||
};
|
};
|
||||||
imageData = [{ localPath: pathAnimatedSnapshot, href: href }];
|
imageData = [{ localPath: pathAnimatedSnapshot, href: href }];
|
||||||
tablet.emitScriptEvent(JSON.stringify({
|
tablet.emitScriptEvent(JSON.stringify({
|
||||||
|
|
Loading…
Reference in a new issue