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

Unified Diff: components/test_runner/text_input_controller.cc

Issue 2012823003: Move IME related functions from WebFrame to WebLocalFrame (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sync Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: components/test_runner/text_input_controller.cc
diff --git a/components/test_runner/text_input_controller.cc b/components/test_runner/text_input_controller.cc
index 4a7b4522fdd724541619861ad96986baf63b44b5..aae454c740d973f6e4a1a12de55b0dbd5a514cff 100644
--- a/components/test_runner/text_input_controller.cc
+++ b/components/test_runner/text_input_controller.cc
@@ -167,7 +167,8 @@ void TextInputController::UnmarkText() {
void TextInputController::DoCommand(const std::string& text) {
if (view()->mainFrame())
- view()->mainFrame()->executeCommand(blink::WebString::fromUTF8(text));
+ view()->mainFrame()->toWebLocalFrame()->executeCommand(
+ blink::WebString::fromUTF8(text));
}
void TextInputController::SetMarkedText(const std::string& text,
@@ -199,14 +200,15 @@ void TextInputController::SetMarkedText(const std::string& text,
}
bool TextInputController::HasMarkedText() {
- return view()->mainFrame() && view()->mainFrame()->hasMarkedText();
+ return view()->mainFrame() &&
+ view()->mainFrame()->toWebLocalFrame()->hasMarkedText();
}
std::vector<int> TextInputController::MarkedRange() {
if (!view()->mainFrame())
return std::vector<int>();
- blink::WebRange range = view()->mainFrame()->markedRange();
+ blink::WebRange range = view()->mainFrame()->toWebLocalFrame()->markedRange();
std::vector<int> int_array(2);
int_array[0] = range.startOffset();
int_array[1] = range.endOffset();
@@ -218,7 +220,8 @@ std::vector<int> TextInputController::SelectedRange() {
if (!view()->mainFrame())
return std::vector<int>();
- blink::WebRange range = view()->mainFrame()->selectionRange();
+ blink::WebRange range =
+ view()->mainFrame()->toWebLocalFrame()->selectionRange();
std::vector<int> int_array(2);
int_array[0] = range.startOffset();
int_array[1] = range.endOffset();

Powered by Google App Engine
This is Rietveld 408576698