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

Side by Side Diff: content/browser/browser_plugin/browser_plugin_embedder.h

Issue 133013007: BrowserPlugin: Minimize BrowserPluginEmbedder static casts (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 11 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 | content/browser/browser_plugin/browser_plugin_embedder.cc » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // A BrowserPluginEmbedder handles messages coming from a BrowserPlugin's 5 // A BrowserPluginEmbedder handles messages coming from a BrowserPlugin's
6 // embedder that are not directed at any particular existing guest process. 6 // embedder that are not directed at any particular existing guest process.
7 // In the beginning, when a BrowserPlugin instance in the embedder renderer 7 // In the beginning, when a BrowserPlugin instance in the embedder renderer
8 // process requests an initial navigation, the WebContents for that renderer 8 // process requests an initial navigation, the WebContents for that renderer
9 // renderer creates a BrowserPluginEmbedder for itself. The 9 // renderer creates a BrowserPluginEmbedder for itself. The
10 // BrowserPluginEmbedder, in turn, forwards the requests to a 10 // BrowserPluginEmbedder, in turn, forwards the requests to a
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 static BrowserPluginEmbedder* Create(WebContentsImpl* web_contents); 45 static BrowserPluginEmbedder* Create(WebContentsImpl* web_contents);
46 46
47 // Returns the RenderViewHost at a point (|x|, |y|) asynchronously via 47 // Returns the RenderViewHost at a point (|x|, |y|) asynchronously via
48 // |callback|. We need a roundtrip to renderer process to get this 48 // |callback|. We need a roundtrip to renderer process to get this
49 // information. 49 // information.
50 void GetRenderViewHostAtPosition( 50 void GetRenderViewHostAtPosition(
51 int x, 51 int x,
52 int y, 52 int y,
53 const WebContents::GetRenderViewHostCallback& callback); 53 const WebContents::GetRenderViewHostCallback& callback);
54 54
55 // Returns this embedder's WebContentsImpl.
56 WebContentsImpl* GetWebContents();
57
55 // Called when embedder's |rwh| has sent screen rects to renderer. 58 // Called when embedder's |rwh| has sent screen rects to renderer.
56 void DidSendScreenRects(); 59 void DidSendScreenRects();
57 60
58 // Called when embedder's WebContentsImpl has unhandled keyboard input. 61 // Called when embedder's WebContentsImpl has unhandled keyboard input.
59 // Returns whether the BrowserPlugin has handled the keyboard event. 62 // Returns whether the BrowserPlugin has handled the keyboard event.
60 // Currently we are only interested in checking for the escape key to 63 // Currently we are only interested in checking for the escape key to
61 // unlock hte guest's pointer lock. 64 // unlock hte guest's pointer lock.
62 bool HandleKeyboardEvent(const NativeWebKeyboardEvent& event); 65 bool HandleKeyboardEvent(const NativeWebKeyboardEvent& event);
63 66
64 // Overrides factory for testing. Default (NULL) value indicates regular 67 // Overrides factory for testing. Default (NULL) value indicates regular
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 // Pointer to the guest that started the drag, used to forward necessary drag 143 // Pointer to the guest that started the drag, used to forward necessary drag
141 // status messages to the correct guest. 144 // status messages to the correct guest.
142 base::WeakPtr<BrowserPluginGuest> guest_started_drag_; 145 base::WeakPtr<BrowserPluginGuest> guest_started_drag_;
143 146
144 DISALLOW_COPY_AND_ASSIGN(BrowserPluginEmbedder); 147 DISALLOW_COPY_AND_ASSIGN(BrowserPluginEmbedder);
145 }; 148 };
146 149
147 } // namespace content 150 } // namespace content
148 151
149 #endif // CONTENT_BROWSER_BROWSER_PLUGIN_BROWSER_PLUGIN_EMBEDDER_H_ 152 #endif // CONTENT_BROWSER_BROWSER_PLUGIN_BROWSER_PLUGIN_EMBEDDER_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/browser_plugin/browser_plugin_embedder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698