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

Side by Side Diff: content/public/test/render_view_test.cc

Issue 812033016: Add RenderFrameObserver::FocusedNodeChanged (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix bad merge Created 5 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
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 #include "content/public/test/render_view_test.h" 5 #include "content/public/test/render_view_test.h"
6 6
7 #include "base/run_loop.h" 7 #include "base/run_loop.h"
8 #include "content/common/dom_storage/dom_storage_types.h" 8 #include "content/common/dom_storage/dom_storage_types.h"
9 #include "content/common/frame_messages.h" 9 #include "content/common/frame_messages.h"
10 #include "content/common/input_messages.h" 10 #include "content/common/input_messages.h"
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); 336 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_);
337 impl->OnMessageReceived( 337 impl->OnMessageReceived(
338 InputMsg_HandleInputEvent(0, &mouse_event, ui::LatencyInfo(), false)); 338 InputMsg_HandleInputEvent(0, &mouse_event, ui::LatencyInfo(), false));
339 mouse_event.type = WebInputEvent::MouseUp; 339 mouse_event.type = WebInputEvent::MouseUp;
340 impl->OnMessageReceived( 340 impl->OnMessageReceived(
341 InputMsg_HandleInputEvent(0, &mouse_event, ui::LatencyInfo(), false)); 341 InputMsg_HandleInputEvent(0, &mouse_event, ui::LatencyInfo(), false));
342 } 342 }
343 343
344 void RenderViewTest::SetFocused(const blink::WebNode& node) { 344 void RenderViewTest::SetFocused(const blink::WebNode& node) {
345 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); 345 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_);
346 impl->focusedNodeChanged(node); 346 impl->focusedNodeChanged(blink::WebNode(), node);
347 } 347 }
348 348
349 void RenderViewTest::Reload(const GURL& url) { 349 void RenderViewTest::Reload(const GURL& url) {
350 FrameMsg_Navigate_Params params; 350 FrameMsg_Navigate_Params params;
351 params.common_params.url = url; 351 params.common_params.url = url;
352 params.common_params.navigation_type = FrameMsg_Navigate_Type::RELOAD; 352 params.common_params.navigation_type = FrameMsg_Navigate_Type::RELOAD;
353 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); 353 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_);
354 impl->GetMainRenderFrame()->OnNavigate(params); 354 impl->GetMainRenderFrame()->OnNavigate(params);
355 FrameLoadWaiter(impl->GetMainRenderFrame()).Wait(); 355 FrameLoadWaiter(impl->GetMainRenderFrame()).Wait();
356 } 356 }
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
439 FrameMsg_Navigate navigate_message(impl->GetMainRenderFrame()->GetRoutingID(), 439 FrameMsg_Navigate navigate_message(impl->GetMainRenderFrame()->GetRoutingID(),
440 navigate_params); 440 navigate_params);
441 impl->GetMainRenderFrame()->OnMessageReceived(navigate_message); 441 impl->GetMainRenderFrame()->OnMessageReceived(navigate_message);
442 442
443 // The load actually happens asynchronously, so we pump messages to process 443 // The load actually happens asynchronously, so we pump messages to process
444 // the pending continuation. 444 // the pending continuation.
445 FrameLoadWaiter(view_->GetMainRenderFrame()).Wait(); 445 FrameLoadWaiter(view_->GetMainRenderFrame()).Wait();
446 } 446 }
447 447
448 } // namespace content 448 } // namespace content
OLDNEW
« no previous file with comments | « content/public/renderer/render_frame_observer.h ('k') | content/renderer/accessibility/renderer_accessibility.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698