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

Unified Diff: third_party/WebKit/Source/core/editing/InputMethodController.cpp

Issue 2668903003: Replace WTF::emptyString{16Bit}() with a static global (Closed)
Patch Set: Replace WTF::emptyString{16Bit}() with a static global Created 3 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/editing/InputMethodController.cpp
diff --git a/third_party/WebKit/Source/core/editing/InputMethodController.cpp b/third_party/WebKit/Source/core/editing/InputMethodController.cpp
index 7836f45cb9db8d292ae5da5f9c605a0f341f5530..6678945ae9d9f44b016017d717c74d0514d95c4c 100644
--- a/third_party/WebKit/Source/core/editing/InputMethodController.cpp
+++ b/third_party/WebKit/Source/core/editing/InputMethodController.cpp
@@ -438,9 +438,9 @@ void InputMethodController::cancelComposition() {
document().focusedElement(),
InputEvent::InputType::DeleteComposedCharacterBackward, nullAtom,
InputEvent::EventCancelable::NotCancelable);
- dispatchCompositionUpdateEvent(frame(), emptyString());
+ dispatchCompositionUpdateEvent(frame(), emptyString);
insertTextDuringCompositionWithEvents(
- frame(), emptyString(), 0,
+ frame(), emptyString, 0,
TypingCommand::TextCompositionType::TextCompositionCancel);
// Event handler might destroy document.
if (!isAvailable())
@@ -451,7 +451,7 @@ void InputMethodController::cancelComposition() {
TypingCommand::closeTyping(m_frame);
// No DOM update after 'compositionend'.
- dispatchCompositionEndEvent(frame(), emptyString());
+ dispatchCompositionEndEvent(frame(), emptyString);
}
void InputMethodController::cancelCompositionIfSelectionIsInvalid() {
@@ -542,7 +542,7 @@ void InputMethodController::setComposition(
if (text.isEmpty()) {
if (hasComposition()) {
Editor::RevealSelectionScope revealSelectionScope(&editor());
- replaceComposition(emptyString());
+ replaceComposition(emptyString);
} else {
// It's weird to call |setComposition()| with empty text outside
// composition, however some IME (e.g. Japanese IBus-Anthy) did this, so
« no previous file with comments | « third_party/WebKit/Source/core/dom/Text.cpp ('k') | third_party/WebKit/Source/core/editing/InputMethodControllerTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698