summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/Source/web/NotificationPermissionClientImpl.h
blob: 106c3be53c593c0163677a632b26c586d34e23c7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
// Copyright 2014 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 NotificationPermissionClientImpl_h
#define NotificationPermissionClientImpl_h

#include "modules/notifications/NotificationPermissionClient.h"
#include "platform/heap/Handle.h"

namespace blink {

class NotificationPermissionClientImpl : public NoBaseWillBeGarbageCollectedFinalized<NotificationPermissionClientImpl>, public NotificationPermissionClient {
    WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(NotificationPermissionClientImpl);
public:
    static PassOwnPtrWillBeRawPtr<NotificationPermissionClientImpl> create();

    ~NotificationPermissionClientImpl() override;

    // NotificationPermissionClient implementation.
    ScriptPromise requestPermission(ScriptState*, NotificationPermissionCallback*) override;

    // NoBaseWillBeGarbageCollectedFinalized implementation.
    DEFINE_INLINE_VIRTUAL_TRACE() { NotificationPermissionClient::trace(visitor); }

private:
    NotificationPermissionClientImpl();
};

} // namespace blink

#endif // NotificationPermissionClientImpl_h