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

Side by Side Diff: content/browser/browser_plugin/browser_plugin_guest_manager.cc

Issue 63253002: Rename WebKit namespace to blink (part 3) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 #include "content/browser/browser_plugin/browser_plugin_guest_manager.h" 5 #include "content/browser/browser_plugin/browser_plugin_guest_manager.h"
6 6
7 #include "content/browser/browser_plugin/browser_plugin_guest.h" 7 #include "content/browser/browser_plugin/browser_plugin_guest.h"
8 #include "content/browser/browser_plugin/browser_plugin_host_factory.h" 8 #include "content/browser/browser_plugin/browser_plugin_host_factory.h"
9 #include "content/browser/renderer_host/render_view_host_impl.h" 9 #include "content/browser/renderer_host/render_view_host_impl.h"
10 #include "content/browser/web_contents/web_contents_impl.h" 10 #include "content/browser/web_contents/web_contents_impl.h"
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 if (embedder_web_contents == guest->embedder_web_contents()) { 238 if (embedder_web_contents == guest->embedder_web_contents()) {
239 static_cast<RenderViewHostImpl*>( 239 static_cast<RenderViewHostImpl*>(
240 guest->GetWebContents()->GetRenderViewHost())->SendScreenRects(); 240 guest->GetWebContents()->GetRenderViewHost())->SendScreenRects();
241 } 241 }
242 } 242 }
243 } 243 }
244 244
245 bool BrowserPluginGuestManager::UnlockMouseIfNecessary( 245 bool BrowserPluginGuestManager::UnlockMouseIfNecessary(
246 WebContentsImpl* embedder_web_contents, 246 WebContentsImpl* embedder_web_contents,
247 const NativeWebKeyboardEvent& event) { 247 const NativeWebKeyboardEvent& event) {
248 if ((event.type != WebKit::WebInputEvent::RawKeyDown) || 248 if ((event.type != blink::WebInputEvent::RawKeyDown) ||
249 (event.windowsKeyCode != ui::VKEY_ESCAPE) || 249 (event.windowsKeyCode != ui::VKEY_ESCAPE) ||
250 (event.modifiers & WebKit::WebInputEvent::InputModifiers)) { 250 (event.modifiers & blink::WebInputEvent::InputModifiers)) {
251 return false; 251 return false;
252 } 252 }
253 253
254 // TODO(lazyboy): Generalize iterating over guest instances and performing 254 // TODO(lazyboy): Generalize iterating over guest instances and performing
255 // actions on the guests. 255 // actions on the guests.
256 for (GuestInstanceMap::iterator it = 256 for (GuestInstanceMap::iterator it =
257 guest_web_contents_by_instance_id_.begin(); 257 guest_web_contents_by_instance_id_.begin();
258 it != guest_web_contents_by_instance_id_.end(); ++it) { 258 it != guest_web_contents_by_instance_id_.end(); ++it) {
259 BrowserPluginGuest* guest = it->second->GetBrowserPluginGuest(); 259 BrowserPluginGuest* guest = it->second->GetBrowserPluginGuest();
260 if (embedder_web_contents == guest->embedder_web_contents()) { 260 if (embedder_web_contents == guest->embedder_web_contents()) {
261 if (guest->UnlockMouseIfNecessary(event)) 261 if (guest->UnlockMouseIfNecessary(event))
262 return true; 262 return true;
263 } 263 }
264 } 264 }
265 return false; 265 return false;
266 } 266 }
267 267
268 } // namespace content 268 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698