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

Side by Side Diff: content/renderer/render_widget.cc

Issue 1889313002: Revert of Browser Side Text Input State Tracking for OOPIF (Manual). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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/renderer/render_widget.h" 5 #include "content/renderer/render_widget.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
(...skipping 20 matching lines...) Expand all
31 #include "components/scheduler/renderer/render_widget_scheduling_state.h" 31 #include "components/scheduler/renderer/render_widget_scheduling_state.h"
32 #include "components/scheduler/renderer/renderer_scheduler.h" 32 #include "components/scheduler/renderer/renderer_scheduler.h"
33 #include "content/common/content_switches_internal.h" 33 #include "content/common/content_switches_internal.h"
34 #include "content/common/gpu/client/context_provider_command_buffer.h" 34 #include "content/common/gpu/client/context_provider_command_buffer.h"
35 #include "content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h" 35 #include "content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h"
36 #include "content/common/gpu_process_launch_causes.h" 36 #include "content/common/gpu_process_launch_causes.h"
37 #include "content/common/input/synthetic_gesture_packet.h" 37 #include "content/common/input/synthetic_gesture_packet.h"
38 #include "content/common/input/web_input_event_traits.h" 38 #include "content/common/input/web_input_event_traits.h"
39 #include "content/common/input_messages.h" 39 #include "content/common/input_messages.h"
40 #include "content/common/swapped_out_messages.h" 40 #include "content/common/swapped_out_messages.h"
41 #include "content/common/text_input_state.h"
42 #include "content/common/view_messages.h" 41 #include "content/common/view_messages.h"
43 #include "content/public/common/content_features.h" 42 #include "content/public/common/content_features.h"
44 #include "content/public/common/content_switches.h" 43 #include "content/public/common/content_switches.h"
45 #include "content/public/common/context_menu_params.h" 44 #include "content/public/common/context_menu_params.h"
46 #include "content/renderer/cursor_utils.h" 45 #include "content/renderer/cursor_utils.h"
47 #include "content/renderer/devtools/render_widget_screen_metrics_emulator.h" 46 #include "content/renderer/devtools/render_widget_screen_metrics_emulator.h"
48 #include "content/renderer/external_popup_menu.h" 47 #include "content/renderer/external_popup_menu.h"
49 #include "content/renderer/gpu/compositor_output_surface.h" 48 #include "content/renderer/gpu/compositor_output_surface.h"
50 #include "content/renderer/gpu/delegated_compositor_output_surface.h" 49 #include "content/renderer/gpu/delegated_compositor_output_surface.h"
51 #include "content/renderer/gpu/frame_swap_message_queue.h" 50 #include "content/renderer/gpu/frame_swap_message_queue.h"
(...skipping 1017 matching lines...) Expand 10 before | Expand all | Expand 10 after
1069 // shown. 1068 // shown.
1070 if (show_ime == ShowIme::IF_NEEDED || 1069 if (show_ime == ShowIme::IF_NEEDED ||
1071 (IsUsingImeThread() && change_source == ChangeSource::FROM_IME) || 1070 (IsUsingImeThread() && change_source == ChangeSource::FROM_IME) ||
1072 (text_input_type_ != new_type || text_input_mode_ != new_mode || 1071 (text_input_type_ != new_type || text_input_mode_ != new_mode ||
1073 text_input_info_ != new_info || 1072 text_input_info_ != new_info ||
1074 can_compose_inline_ != new_can_compose_inline) 1073 can_compose_inline_ != new_can_compose_inline)
1075 #if defined(OS_ANDROID) 1074 #if defined(OS_ANDROID)
1076 || text_field_is_dirty_ 1075 || text_field_is_dirty_
1077 #endif 1076 #endif
1078 ) { 1077 ) {
1079 TextInputState params; 1078 ViewHostMsg_TextInputState_Params params;
1080 params.type = new_type; 1079 params.type = new_type;
1081 params.mode = new_mode; 1080 params.mode = new_mode;
1082 params.flags = new_info.flags; 1081 params.flags = new_info.flags;
1083 params.value = new_info.value.utf8(); 1082 params.value = new_info.value.utf8();
1084 params.selection_start = new_info.selectionStart; 1083 params.selection_start = new_info.selectionStart;
1085 params.selection_end = new_info.selectionEnd; 1084 params.selection_end = new_info.selectionEnd;
1086 params.composition_start = new_info.compositionStart; 1085 params.composition_start = new_info.compositionStart;
1087 params.composition_end = new_info.compositionEnd; 1086 params.composition_end = new_info.compositionEnd;
1088 params.can_compose_inline = new_can_compose_inline; 1087 params.can_compose_inline = new_can_compose_inline;
1089 params.show_ime_if_needed = (show_ime == ShowIme::IF_NEEDED); 1088 params.show_ime_if_needed = (show_ime == ShowIme::IF_NEEDED);
(...skipping 1094 matching lines...) Expand 10 before | Expand all | Expand 10 after
2184 } 2183 }
2185 2184
2186 float RenderWidget::GetOriginalDeviceScaleFactor() const { 2185 float RenderWidget::GetOriginalDeviceScaleFactor() const {
2187 return 2186 return
2188 screen_metrics_emulator_ ? 2187 screen_metrics_emulator_ ?
2189 screen_metrics_emulator_->original_screen_info().deviceScaleFactor : 2188 screen_metrics_emulator_->original_screen_info().deviceScaleFactor :
2190 device_scale_factor_; 2189 device_scale_factor_;
2191 } 2190 }
2192 2191
2193 } // namespace content 2192 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_view_browsertest.cc ('k') | content/test/data/textinput/page_with_input.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698