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

Side by Side Diff: Source/modules/presentation/DefaultSessionStartEvent.h

Issue 974993002: [Presentation API] Added the DefaultPresentationStart event and parsing of the default presentation… (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed last reviewers wishes Created 5 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 unified diff | Download patch
« no previous file with comments | « Source/modules/modules.gypi ('k') | Source/modules/presentation/DefaultSessionStartEvent.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef DefaultSessionStartEvent_h
6 #define DefaultSessionStartEvent_h
7
8 #include "modules/EventModules.h"
9 #include "modules/presentation/PresentationSession.h"
10 #include "platform/heap/Handle.h"
11
12 namespace blink {
13
14 class DefaultSessionStartEventInit;
15
16 // Presentation API event to be fired when a presentation has been triggered
17 // by the embedder using the default presentation URL and id.
18 // See https://code.google.com/p/chromium/issues/detail?id=459001 for details.
19 class DefaultSessionStartEvent final : public Event {
20 DEFINE_WRAPPERTYPEINFO();
21 public:
22 virtual ~DefaultSessionStartEvent();
23
24 static PassRefPtrWillBeRawPtr<DefaultSessionStartEvent> create()
25 {
26 return adoptRefWillBeNoop(new DefaultSessionStartEvent);
27 }
28 static PassRefPtrWillBeRawPtr<DefaultSessionStartEvent> create(const AtomicS tring& eventType, PresentationSession* session)
29 {
30 return adoptRefWillBeNoop(new DefaultSessionStartEvent(eventType, sessio n));
31 }
32 static PassRefPtrWillBeRawPtr<DefaultSessionStartEvent> create(const AtomicS tring& eventType, const DefaultSessionStartEventInit& initializer)
33 {
34 return adoptRefWillBeNoop(new DefaultSessionStartEvent(eventType, initia lizer));
35 }
36
37 PresentationSession* session() { return m_session.get(); }
38
39 virtual const AtomicString& interfaceName() const override;
40
41 private:
42 DefaultSessionStartEvent();
43 DefaultSessionStartEvent(const AtomicString& eventType, PresentationSession* );
44 DefaultSessionStartEvent(const AtomicString& eventType, const DefaultSession StartEventInit& initializer);
45
46 Persistent<PresentationSession> m_session;
47 };
48
49 DEFINE_TYPE_CASTS(DefaultSessionStartEvent, Event, event, event->interfaceName() == EventNames::DefaultSessionStartEvent, event.interfaceName() == EventNames::D efaultSessionStartEvent);
50
51 } // namespace blink
52
53 #endif // DefaultSessionStartEvent_h
OLDNEW
« no previous file with comments | « Source/modules/modules.gypi ('k') | Source/modules/presentation/DefaultSessionStartEvent.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698