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

Unified Diff: Source/modules/background_sync/PeriodicSyncEvent.h

Issue 1096503002: [Background Sync] Converting Blink code to the MVP API (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Unregister method requires the sync registration tag Created 5 years, 8 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
« no previous file with comments | « Source/core/events/EventTypeNames.in ('k') | Source/modules/background_sync/PeriodicSyncEvent.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/background_sync/PeriodicSyncEvent.h
diff --git a/Source/modules/background_sync/PeriodicSyncEvent.h b/Source/modules/background_sync/PeriodicSyncEvent.h
new file mode 100644
index 0000000000000000000000000000000000000000..94d30c20a2b6eee6b4c2fe30978520cc850a10cf
--- /dev/null
+++ b/Source/modules/background_sync/PeriodicSyncEvent.h
@@ -0,0 +1,51 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef PeriodicSyncEvent_h
+#define PeriodicSyncEvent_h
+
+#include "modules/EventModules.h"
+#include "modules/serviceworkers/ExtendableEvent.h"
+#include "wtf/text/AtomicString.h"
+
+namespace blink {
+
+class PeriodicSyncEventInit;
+class PeriodicSyncRegistration;
+
+class PeriodicSyncEvent final : public ExtendableEvent {
+ DEFINE_WRAPPERTYPEINFO();
+public:
+ static PassRefPtrWillBeRawPtr<PeriodicSyncEvent> create()
+ {
+ return adoptRefWillBeNoop(new PeriodicSyncEvent);
+ }
+ static PassRefPtrWillBeRawPtr<PeriodicSyncEvent> create(const AtomicString& type, PeriodicSyncRegistration* syncRegistration, WaitUntilObserver* observer)
+ {
+ return adoptRefWillBeNoop(new PeriodicSyncEvent(type, syncRegistration, observer));
+ }
+ static PassRefPtrWillBeRawPtr<PeriodicSyncEvent> create(const AtomicString& type, const PeriodicSyncEventInit& init)
+ {
+ return adoptRefWillBeNoop(new PeriodicSyncEvent(type, init));
+ }
+
+ virtual ~PeriodicSyncEvent();
+
+ virtual const AtomicString& interfaceName() const override;
+
+ PeriodicSyncRegistration* registration();
+
+ DECLARE_VIRTUAL_TRACE();
+
+private:
+ PeriodicSyncEvent();
+ PeriodicSyncEvent(const AtomicString& type, PeriodicSyncRegistration*, WaitUntilObserver*);
+ PeriodicSyncEvent(const AtomicString& type, const PeriodicSyncEventInit&);
+
+ PersistentWillBeMember<PeriodicSyncRegistration> m_periodicRegistration;
+};
+
+} // namespace blink
+
+#endif // PeriodicSyncEvent_h
« no previous file with comments | « Source/core/events/EventTypeNames.in ('k') | Source/modules/background_sync/PeriodicSyncEvent.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698