diff options
author | Matt A. Tobin <email@mattatobin.com> | 2020-02-06 19:47:29 -0500 |
---|---|---|
committer | wolfbeast <mcwerewolf@wolfbeast.com> | 2020-04-14 12:31:31 +0200 |
commit | 11a4ab0982caa3a4c22a08a72a134e2c402430ec (patch) | |
tree | df8f3a33c0360fe4be68108d91b516d1a1ce0232 /dom/base | |
parent | 8c41fcd24048154e3526e506157d337a2ab434e8 (diff) | |
download | UXP-11a4ab0982caa3a4c22a08a72a134e2c402430ec.tar UXP-11a4ab0982caa3a4c22a08a72a134e2c402430ec.tar.gz UXP-11a4ab0982caa3a4c22a08a72a134e2c402430ec.tar.lz UXP-11a4ab0982caa3a4c22a08a72a134e2c402430ec.tar.xz UXP-11a4ab0982caa3a4c22a08a72a134e2c402430ec.zip |
Issue #1395 - Remove FlyWeb Service
Diffstat (limited to 'dom/base')
-rw-r--r-- | dom/base/Navigator.cpp | 37 | ||||
-rw-r--r-- | dom/base/Navigator.h | 5 | ||||
-rw-r--r-- | dom/base/nsDocument.cpp | 8 |
3 files changed, 0 insertions, 50 deletions
diff --git a/dom/base/Navigator.cpp b/dom/base/Navigator.cpp index 1433f3257..a544f23c1 100644 --- a/dom/base/Navigator.cpp +++ b/dom/base/Navigator.cpp @@ -37,8 +37,6 @@ #include "mozilla/dom/PowerManager.h" #include "mozilla/dom/WakeLock.h" #include "mozilla/dom/power/PowerManagerService.h" -#include "mozilla/dom/FlyWebPublishedServer.h" -#include "mozilla/dom/FlyWebService.h" #include "mozilla/dom/Permissions.h" #include "mozilla/dom/ServiceWorkerContainer.h" #include "mozilla/dom/StorageManager.h" @@ -1356,41 +1354,6 @@ Navigator::GetBattery(ErrorResult& aRv) return mBatteryPromise; } -already_AddRefed<Promise> -Navigator::PublishServer(const nsAString& aName, - const FlyWebPublishOptions& aOptions, - ErrorResult& aRv) -{ - RefPtr<FlyWebService> service = FlyWebService::GetOrCreate(); - if (!service) { - aRv.Throw(NS_ERROR_FAILURE); - return nullptr; - } - - RefPtr<FlyWebPublishPromise> mozPromise = - service->PublishServer(aName, aOptions, mWindow); - MOZ_ASSERT(mozPromise); - - nsCOMPtr<nsIGlobalObject> global = do_QueryInterface(mWindow); - ErrorResult result; - RefPtr<Promise> domPromise = Promise::Create(global, result); - if (result.Failed()) { - aRv.Throw(NS_ERROR_FAILURE); - return nullptr; - } - - mozPromise->Then(AbstractThread::MainThread(), - __func__, - [domPromise] (FlyWebPublishedServer* aServer) { - domPromise->MaybeResolve(aServer); - }, - [domPromise] (nsresult aStatus) { - domPromise->MaybeReject(aStatus); - }); - - return domPromise.forget(); -} - PowerManager* Navigator::GetMozPower(ErrorResult& aRv) { diff --git a/dom/base/Navigator.h b/dom/base/Navigator.h index c681797fb..4ddaaabab 100644 --- a/dom/base/Navigator.h +++ b/dom/base/Navigator.h @@ -39,8 +39,6 @@ class WakeLock; class ArrayBufferViewOrBlobOrStringOrFormData; class ServiceWorkerContainer; class DOMRequest; -struct FlyWebPublishOptions; -struct FlyWebFilter; } // namespace dom } // namespace mozilla @@ -140,9 +138,6 @@ public: Geolocation* GetGeolocation(ErrorResult& aRv); Promise* GetBattery(ErrorResult& aRv); - already_AddRefed<Promise> PublishServer(const nsAString& aName, - const FlyWebPublishOptions& aOptions, - ErrorResult& aRv); static void AppName(nsAString& aAppName, bool aUsePrefOverriddenValue); static nsresult GetPlatform(nsAString& aPlatform, diff --git a/dom/base/nsDocument.cpp b/dom/base/nsDocument.cpp index afe88a454..380593737 100644 --- a/dom/base/nsDocument.cpp +++ b/dom/base/nsDocument.cpp @@ -166,7 +166,6 @@ #include "mozilla/dom/HTMLIFrameElement.h" #include "mozilla/dom/HTMLImageElement.h" #include "mozilla/dom/MediaSource.h" -#include "mozilla/dom/FlyWebService.h" #include "mozAutoDocUpdate.h" #include "nsGlobalWindow.h" @@ -8369,13 +8368,6 @@ nsDocument::CanSavePresentation(nsIRequest *aNewRequest) return false; } - // Don't save presentation if there are active FlyWeb connections or FlyWeb - // servers. - FlyWebService* flyWebService = FlyWebService::GetExisting(); - if (flyWebService && flyWebService->HasConnectionOrServer(win->WindowID())) { - return false; - } - if (mSubDocuments) { for (auto iter = mSubDocuments->Iter(); !iter.Done(); iter.Next()) { auto entry = static_cast<SubDocMapEntry*>(iter.Get()); |