Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(675)

Unified Diff: third_party/WebKit/Source/modules/background_fetch/BackgroundFetchRegistration.h

Issue 2762663002: BackgroundFetchRegistration.abort() should return a Promise. (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/background_fetch/BackgroundFetchRegistration.h
diff --git a/third_party/WebKit/Source/modules/background_fetch/BackgroundFetchRegistration.h b/third_party/WebKit/Source/modules/background_fetch/BackgroundFetchRegistration.h
index fc9edc321b4fbe9323ab618030051efd9054dfb2..e44ac7c3bb1e7951c0dc5c0a28619711fab38118 100644
--- a/third_party/WebKit/Source/modules/background_fetch/BackgroundFetchRegistration.h
+++ b/third_party/WebKit/Source/modules/background_fetch/BackgroundFetchRegistration.h
@@ -9,11 +9,14 @@
#include "bindings/core/v8/ScriptWrappable.h"
#include "platform/heap/GarbageCollected.h"
#include "platform/heap/Handle.h"
+#include "public/platform/modules/background_fetch/background_fetch.mojom-blink.h"
#include "wtf/text/WTFString.h"
namespace blink {
class IconDefinition;
+class ScriptPromiseResolver;
+class ScriptState;
class ServiceWorkerRegistration;
// Represents an individual Background Fetch registration. Gives developers
@@ -36,11 +39,13 @@ class BackgroundFetchRegistration final
long long totalDownloadSize() const;
String title() const;
- void abort();
+ ScriptPromise abort(ScriptState*);
DECLARE_TRACE();
private:
+ void didAbort(ScriptPromiseResolver*, mojom::blink::BackgroundFetchError);
+
Member<ServiceWorkerRegistration> m_registration;
String m_tag;

Powered by Google App Engine
This is Rietveld 408576698