| Index: Source/modules/background_sync/SyncEvent.h
|
| diff --git a/Source/modules/push_messaging/PushEvent.h b/Source/modules/background_sync/SyncEvent.h
|
| similarity index 32%
|
| copy from Source/modules/push_messaging/PushEvent.h
|
| copy to Source/modules/background_sync/SyncEvent.h
|
| index 22659883d751be3898c9a1f6b0e720e04edc24fd..b45b0185813c69482769517367cd5fcb874f436e 100644
|
| --- a/Source/modules/push_messaging/PushEvent.h
|
| +++ b/Source/modules/background_sync/SyncEvent.h
|
| @@ -1,13 +1,13 @@
|
| -// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// 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 PushEvent_h
|
| -#define PushEvent_h
|
| +#ifndef SyncEvent_h
|
| +#define SyncEvent_h
|
|
|
| #include "modules/EventModules.h"
|
| -#include "modules/push_messaging/PushEventInit.h"
|
| -#include "modules/push_messaging/PushMessageData.h"
|
| +#include "modules/background_sync/SyncEventInit.h"
|
| +#include "modules/background_sync/SyncRegistration.h"
|
| #include "modules/serviceworkers/ExtendableEvent.h"
|
| #include "platform/heap/Handle.h"
|
| #include "wtf/text/AtomicString.h"
|
| @@ -15,38 +15,38 @@
|
|
|
| namespace blink {
|
|
|
| -class PushEvent final : public ExtendableEvent {
|
| +class SyncEvent final : public ExtendableEvent {
|
| DEFINE_WRAPPERTYPEINFO();
|
| public:
|
| - static PassRefPtrWillBeRawPtr<PushEvent> create()
|
| + static PassRefPtrWillBeRawPtr<SyncEvent> create()
|
| {
|
| - return adoptRefWillBeNoop(new PushEvent);
|
| + return adoptRefWillBeNoop(new SyncEvent);
|
| }
|
| - static PassRefPtrWillBeRawPtr<PushEvent> create(const AtomicString& type, PushMessageData* data, WaitUntilObserver* observer)
|
| + static PassRefPtrWillBeRawPtr<SyncEvent> create(const AtomicString& type, SyncRegistration* syncRegistration, WaitUntilObserver* observer)
|
| {
|
| - return adoptRefWillBeNoop(new PushEvent(type, data, observer));
|
| + return adoptRefWillBeNoop(new SyncEvent(type, syncRegistration, observer));
|
| }
|
| - static PassRefPtrWillBeRawPtr<PushEvent> create(const AtomicString& type, const PushEventInit& initializer)
|
| + static PassRefPtrWillBeRawPtr<SyncEvent> create(const AtomicString& type, const SyncEventInit& init)
|
| {
|
| - return adoptRefWillBeNoop(new PushEvent(type, initializer));
|
| + return adoptRefWillBeNoop(new SyncEvent(type, init));
|
| }
|
|
|
| - virtual ~PushEvent();
|
| + virtual ~SyncEvent();
|
|
|
| virtual const AtomicString& interfaceName() const override;
|
|
|
| - PushMessageData* data();
|
| + SyncRegistration* registration();
|
|
|
| DECLARE_VIRTUAL_TRACE();
|
|
|
| private:
|
| - PushEvent();
|
| - PushEvent(const AtomicString& type, PushMessageData*, WaitUntilObserver*);
|
| - PushEvent(const AtomicString& type, const PushEventInit&);
|
| + SyncEvent();
|
| + SyncEvent(const AtomicString& type, SyncRegistration*, WaitUntilObserver*);
|
| + SyncEvent(const AtomicString& type, const SyncEventInit&);
|
|
|
| - PersistentWillBeMember<PushMessageData> m_data;
|
| + PersistentWillBeMember<SyncRegistration> m_syncRegistration;
|
| };
|
|
|
| } // namespace blink
|
|
|
| -#endif // PushEvent_h
|
| +#endif // SyncEvent_h
|
|
|