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

Side by Side Diff: third_party/WebKit/Source/modules/presentation/Presentation.h

Issue 2592073002: Replace DOMWindowProperty in modules/presentation/ with ContextClient (Closed)
Patch Set: Created 3 years, 12 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 | « no previous file | third_party/WebKit/Source/modules/presentation/Presentation.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef Presentation_h 5 #ifndef Presentation_h
6 #define Presentation_h 6 #define Presentation_h
7 7
8 #include "bindings/core/v8/ScriptWrappable.h" 8 #include "bindings/core/v8/ScriptWrappable.h"
9 #include "core/frame/DOMWindowProperty.h" 9 #include "core/dom/ContextLifecycleObserver.h"
10 #include "platform/heap/Handle.h" 10 #include "platform/heap/Handle.h"
11 #include "platform/heap/Heap.h" 11 #include "platform/heap/Heap.h"
12 12
13 namespace blink { 13 namespace blink {
14 14
15 class LocalFrame; 15 class LocalFrame;
16 class PresentationReceiver; 16 class PresentationReceiver;
17 class PresentationRequest; 17 class PresentationRequest;
18 18
19 // Implements the main entry point of the Presentation API corresponding to the 19 // Implements the main entry point of the Presentation API corresponding to the
20 // Presentation.idl 20 // Presentation.idl
21 // See https://w3c.github.io/presentation-api/#navigatorpresentation for 21 // See https://w3c.github.io/presentation-api/#navigatorpresentation for
22 // details. 22 // details.
23 class Presentation final : public GarbageCollected<Presentation>, 23 class Presentation final : public GarbageCollected<Presentation>,
24 public ScriptWrappable, 24 public ScriptWrappable,
25 public DOMWindowProperty { 25 public ContextClient {
26 USING_GARBAGE_COLLECTED_MIXIN(Presentation); 26 USING_GARBAGE_COLLECTED_MIXIN(Presentation);
27 DEFINE_WRAPPERTYPEINFO(); 27 DEFINE_WRAPPERTYPEINFO();
28 28
29 public: 29 public:
30 static Presentation* create(LocalFrame*); 30 static Presentation* create(LocalFrame*);
31 31
32 DECLARE_VIRTUAL_TRACE(); 32 DECLARE_VIRTUAL_TRACE();
33 33
34 PresentationRequest* defaultRequest() const; 34 PresentationRequest* defaultRequest() const;
35 void setDefaultRequest(PresentationRequest*); 35 void setDefaultRequest(PresentationRequest*);
36 36
37 PresentationReceiver* receiver(); 37 PresentationReceiver* receiver();
38 38
39 private: 39 private:
40 explicit Presentation(LocalFrame*); 40 explicit Presentation(LocalFrame*);
41 41
42 // Default PresentationRequest used by the embedder. 42 // Default PresentationRequest used by the embedder.
43 Member<PresentationRequest> m_defaultRequest; 43 Member<PresentationRequest> m_defaultRequest;
44 44
45 // PresentationReceiver instance. It will always be nullptr if the Blink 45 // PresentationReceiver instance. It will always be nullptr if the Blink
46 // instance is not running as a presentation receiver. 46 // instance is not running as a presentation receiver.
47 Member<PresentationReceiver> m_receiver; 47 Member<PresentationReceiver> m_receiver;
48 }; 48 };
49 49
50 } // namespace blink 50 } // namespace blink
51 51
52 #endif // Presentation_h 52 #endif // Presentation_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/presentation/Presentation.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698