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

Side by Side Diff: Source/web/PluginPlaceholderImpl.h

Issue 1313763002: Blink Plugins: Remove Shadow DOM Plugin Placeholder (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: merge origin/master Created 5 years, 3 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/web/FrameLoaderClientImpl.cpp ('k') | Source/web/PluginPlaceholderImpl.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 2014 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 PluginPlaceholderImpl_h
6 #define PluginPlaceholderImpl_h
7
8 #include "core/plugins/PluginPlaceholder.h"
9 #include "platform/heap/Handle.h"
10 #include "platform/heap/Visitor.h"
11 #include "wtf/Assertions.h"
12 #include "wtf/OwnPtr.h"
13 #include "wtf/PassOwnPtr.h"
14
15 namespace blink {
16
17 class Document;
18 class PluginPlaceholderElement;
19 class WebPluginPlaceholder;
20
21 // Populates a plugin placeholder element with content supplied by the embedder.
22 // Intended to be loaded into a user agent shadow root, but will accept any
23 // container. Owns a WebPluginPlaceholder instance.
24 class PluginPlaceholderImpl : public NoBaseWillBeGarbageCollectedFinalized<Plugi nPlaceholderImpl>, public PluginPlaceholder {
25 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(PluginPlaceholderImpl);
26 public:
27 static PassOwnPtrWillBeRawPtr<PluginPlaceholderImpl> create(PassOwnPtr<WebPl uginPlaceholder> webPluginPlaceholder, Document& document)
28 {
29 ASSERT(webPluginPlaceholder);
30 return adoptPtrWillBeNoop(new PluginPlaceholderImpl(webPluginPlaceholder , document));
31 }
32
33 #if ENABLE(OILPAN)
34 ~PluginPlaceholderImpl();
35 #else
36 ~PluginPlaceholderImpl() override;
37 #endif
38
39 DECLARE_VIRTUAL_TRACE();
40
41 // PluginPlaceholder methods
42 void loadIntoContainer(ContainerNode&) override;
43
44 // Visible for testing.
45 WebPluginPlaceholder* webPluginPlaceholder() const { return m_webPluginPlace holder.get(); }
46
47 private:
48 PluginPlaceholderImpl(PassOwnPtr<WebPluginPlaceholder>, Document&);
49
50 // Update the placeholder element with fresh content.
51 void update();
52
53 OwnPtr<WebPluginPlaceholder> m_webPluginPlaceholder;
54 RefPtrWillBeMember<PluginPlaceholderElement> m_placeholderElement;
55 };
56
57 } // namespace blink
58
59 #endif // PluginPlaceholderImpl_h
OLDNEW
« no previous file with comments | « Source/web/FrameLoaderClientImpl.cpp ('k') | Source/web/PluginPlaceholderImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698