mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-25 13:32:54 +02:00
Make --url take existing Interface to FILE, HTTP, and HTTPS serverless
This commit is contained in:
parent
fa30866701
commit
ad427e31a7
2 changed files with 4 additions and 2 deletions
|
@ -9263,7 +9263,7 @@ void Application::readArgumentsFromLocalSocket() const {
|
|||
|
||||
// If we received a message, try to open it as a URL
|
||||
if (message.length() > 0) {
|
||||
DependencyManager::get<WindowScriptingInterface>()->openUrl(QString::fromUtf8(message));
|
||||
DependencyManager::get<AddressManager>()->handleLookupString(QString::fromUtf8(message));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -262,7 +262,9 @@ int main(int argc, const char* argv[]) {
|
|||
if (socket.waitForConnected(LOCAL_SERVER_TIMEOUT_MS)) {
|
||||
if (parser.isSet(urlOption)) {
|
||||
QUrl url = QUrl(parser.value(urlOption));
|
||||
if (url.isValid() && (url.scheme() == URL_SCHEME_HIFI || url.scheme() == URL_SCHEME_HIFIAPP)) {
|
||||
if (url.isValid() && (url.scheme() == URL_SCHEME_HIFI || url.scheme() == URL_SCHEME_HIFIAPP
|
||||
|| url.scheme() == HIFI_URL_SCHEME_HTTP || url.scheme() == HIFI_URL_SCHEME_HTTPS
|
||||
|| url.scheme() == HIFI_URL_SCHEME_FILE)) {
|
||||
qDebug() << "Writing URL to local socket";
|
||||
socket.write(url.toString().toUtf8());
|
||||
if (!socket.waitForBytesWritten(5000)) {
|
||||
|
|
Loading…
Reference in a new issue