diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index aadfa59294..3ad0fa9392 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -513,18 +513,18 @@ bool isDomainURL(QUrl url) { if (!url.isValid()) { return false; } - if (url.scheme() != HIFI_URL_SCHEME && - url.scheme() != "file" && + if (url.scheme() == HIFI_URL_SCHEME) { + return true; + } + if (url.scheme() != "file" && url.scheme() != "http" && url.scheme() != "https") { return false; } - - if (url.path().endsWith(".domain.json", Qt::CaseInsensitive) || - url.path().endsWith(".domain.json.gz", Qt::CaseInsensitive)) { + if (url.path().endsWith(".json", Qt::CaseInsensitive) || + url.path().endsWith(".json.gz", Qt::CaseInsensitive)) { return true; } - return false; } @@ -6264,8 +6264,7 @@ bool Application::canAcceptURL(const QString& urlString) const { bool Application::acceptURL(const QString& urlString, bool defaultUpload) { QUrl url(urlString); if (isDomainURL(url)) { - // this is a hifi URL - have the AddressManager handle it - emit receivedHifiSchemeURL(urlString); + // this is a URL for a domain, either hifi:// or serverless - have the AddressManager handle it QMetaObject::invokeMethod(DependencyManager::get().data(), "handleLookupString", Qt::AutoConnection, Q_ARG(const QString&, urlString)); return true; diff --git a/interface/src/Application.h b/interface/src/Application.h index ef110b2cfb..948916ba7c 100644 --- a/interface/src/Application.h +++ b/interface/src/Application.h @@ -299,7 +299,6 @@ signals: void activeDisplayPluginChanged(); void uploadRequest(QString path); - void receivedHifiSchemeURL(const QString& url); public slots: QVector pasteEntities(float x, float y, float z); diff --git a/interface/src/ui/AddressBarDialog.cpp b/interface/src/ui/AddressBarDialog.cpp index 1a23674fa3..87bf09a252 100644 --- a/interface/src/ui/AddressBarDialog.cpp +++ b/interface/src/ui/AddressBarDialog.cpp @@ -45,7 +45,6 @@ AddressBarDialog::AddressBarDialog(QQuickItem* parent) : OffscreenQmlDialog(pare connect(&domainHandler, &DomainHandler::connectedToDomain, this, &AddressBarDialog::hostChanged); connect(&domainHandler, &DomainHandler::disconnectedFromDomain, this, &AddressBarDialog::hostChanged); connect(DependencyManager::get().data(), &DialogsManager::setUseFeed, this, &AddressBarDialog::setUseFeed); - connect(qApp, &Application::receivedHifiSchemeURL, this, &AddressBarDialog::receivedHifiSchemeURL); } void AddressBarDialog::loadAddress(const QString& address, bool fromSuggestions) { diff --git a/interface/src/ui/AddressBarDialog.h b/interface/src/ui/AddressBarDialog.h index 7806436774..1254fabbd2 100644 --- a/interface/src/ui/AddressBarDialog.h +++ b/interface/src/ui/AddressBarDialog.h @@ -36,7 +36,6 @@ signals: void backEnabledChanged(); void forwardEnabledChanged(); void useFeedChanged(); - void receivedHifiSchemeURL(const QString& url); void hostChanged(); protected: diff --git a/libraries/entities/src/EntityTree.cpp b/libraries/entities/src/EntityTree.cpp index cc52f5b822..46b6a689d0 100644 --- a/libraries/entities/src/EntityTree.cpp +++ b/libraries/entities/src/EntityTree.cpp @@ -1509,7 +1509,8 @@ int EntityTree::processEditPacketData(ReceivedMessage& message, const unsigned c } if (isAdd && properties.getLocked() && !senderNode->isAllowedEditor()) { - // if a node can't change locks, don't allow them to create an already-locked entity + // if a node can't change locks, don't allow it to create an already-locked entity -- automatically + // clear the locked property and allow the unlocked entity to be created. properties.setLocked(false); bumpTimestamp(properties); }