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

Side by Side Diff: content/browser/web_contents/web_contents_impl.cc

Issue 1080693002: Implementation of Smart GO NEXT feature in Android Chrome (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed indentation and naming convention issues. Created 5 years, 8 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/browser/web_contents/web_contents_impl.h" 5 #include "content/browser/web_contents/web_contents_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 2105 matching lines...) Expand 10 before | Expand all | Expand 10 after
2116 2116
2117 void WebContentsImpl::Unselect() { 2117 void WebContentsImpl::Unselect() {
2118 RenderFrameHost* focused_frame = GetFocusedFrame(); 2118 RenderFrameHost* focused_frame = GetFocusedFrame();
2119 if (!focused_frame) 2119 if (!focused_frame)
2120 return; 2120 return;
2121 2121
2122 focused_frame->Send(new InputMsg_Unselect(focused_frame->GetRoutingID())); 2122 focused_frame->Send(new InputMsg_Unselect(focused_frame->GetRoutingID()));
2123 RecordAction(base::UserMetricsAction("Unselect")); 2123 RecordAction(base::UserMetricsAction("Unselect"));
2124 } 2124 }
2125 2125
2126 void WebContentsImpl::AdvanceFocusToNextFormControl(bool forward) {
2127 RenderViewHost* render_view_host = GetRenderViewHost();
2128 if (!render_view_host)
2129 return;
2130 render_view_host->Send(new InputMsg_AdvanceFocusToNextFormControl(
2131 render_view_host->GetRoutingID(), forward));
2132 }
2133
2126 void WebContentsImpl::Replace(const base::string16& word) { 2134 void WebContentsImpl::Replace(const base::string16& word) {
2127 RenderFrameHost* focused_frame = GetFocusedFrame(); 2135 RenderFrameHost* focused_frame = GetFocusedFrame();
2128 if (!focused_frame) 2136 if (!focused_frame)
2129 return; 2137 return;
2130 2138
2131 focused_frame->Send(new InputMsg_Replace( 2139 focused_frame->Send(new InputMsg_Replace(
2132 focused_frame->GetRoutingID(), word)); 2140 focused_frame->GetRoutingID(), word));
2133 } 2141 }
2134 2142
2135 void WebContentsImpl::ReplaceMisspelling(const base::string16& word) { 2143 void WebContentsImpl::ReplaceMisspelling(const base::string16& word) {
(...skipping 2401 matching lines...) Expand 10 before | Expand all | Expand 10 after
4537 node->render_manager()->ResumeResponseDeferredAtStart(); 4545 node->render_manager()->ResumeResponseDeferredAtStart();
4538 } 4546 }
4539 4547
4540 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) { 4548 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) {
4541 force_disable_overscroll_content_ = force_disable; 4549 force_disable_overscroll_content_ = force_disable;
4542 if (view_) 4550 if (view_)
4543 view_->SetOverscrollControllerEnabled(CanOverscrollContent()); 4551 view_->SetOverscrollControllerEnabled(CanOverscrollContent());
4544 } 4552 }
4545 4553
4546 } // namespace content 4554 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698