Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / ui / base / ime / input_method_base_unittest.cc
index 830bba0..129d3c5 100644 (file)
@@ -126,16 +126,11 @@ class InputMethodBaseTest : public testing::Test {
  protected:
   InputMethodBaseTest() {
   }
-  virtual ~InputMethodBaseTest() {
-  }
+  ~InputMethodBaseTest() override {}
 
-  virtual void SetUp() {
-    message_loop_.reset(new base::MessageLoopForUI);
-  }
+  void SetUp() override { message_loop_.reset(new base::MessageLoopForUI); }
 
-  virtual void TearDown() {
-    message_loop_.reset();
-  }
+  void TearDown() override { message_loop_.reset(); }
 
  private:
   scoped_ptr<base::MessageLoop> message_loop_;
@@ -147,42 +142,30 @@ class MockInputMethodBase : public InputMethodBase {
   // Note: this class does not take the ownership of |verifier|.
   MockInputMethodBase(ClientChangeVerifier* verifier) : verifier_(verifier) {
   }
-  virtual ~MockInputMethodBase() {
-  }
+  ~MockInputMethodBase() override {}
 
  private:
   // Overriden from InputMethod.
-  virtual bool OnUntranslatedIMEMessage(
+  bool OnUntranslatedIMEMessage(
       const base::NativeEvent& event,
-      InputMethod::NativeEventResult* result) OVERRIDE {
-    return false;
-  }
-  virtual bool DispatchKeyEvent(const ui::KeyEvent&) OVERRIDE {
-    return false;
-  }
-  virtual void OnCaretBoundsChanged(const TextInputClient* client) OVERRIDE {
-  }
-  virtual void CancelComposition(const TextInputClient* client) OVERRIDE {
-  }
-  virtual void OnInputLocaleChanged() OVERRIDE {
-  }
-  virtual std::string GetInputLocale() OVERRIDE{
-    return "";
-  }
-  virtual bool IsActive() OVERRIDE {
-    return false;
-  }
-  virtual bool IsCandidatePopupOpen() const OVERRIDE {
+      InputMethod::NativeEventResult* result) override {
     return false;
   }
+  bool DispatchKeyEvent(const ui::KeyEvent&) override { return false; }
+  void OnCaretBoundsChanged(const TextInputClient* client) override {}
+  void CancelComposition(const TextInputClient* client) override {}
+  void OnInputLocaleChanged() override {}
+  std::string GetInputLocale() override { return ""; }
+  bool IsActive() override { return false; }
+  bool IsCandidatePopupOpen() const override { return false; }
   // Overriden from InputMethodBase.
-  virtual void OnWillChangeFocusedClient(TextInputClient* focused_before,
-                                         TextInputClient* focused) OVERRIDE {
+  void OnWillChangeFocusedClient(TextInputClient* focused_before,
+                                 TextInputClient* focused) override {
     verifier_->OnWillChangeFocusedClient(focused_before, focused);
   }
 
-  virtual void OnDidChangeFocusedClient(TextInputClient* focused_before,
-                                        TextInputClient* focused) OVERRIDE {
+  void OnDidChangeFocusedClient(TextInputClient* focused_before,
+                                TextInputClient* focused) override {
     verifier_->OnDidChangeFocusedClient(focused_before, focused);
   }
 
@@ -198,25 +181,18 @@ class MockInputMethodObserver : public InputMethodObserver {
   explicit MockInputMethodObserver(ClientChangeVerifier* verifier)
       : verifier_(verifier) {
   }
-  virtual ~MockInputMethodObserver() {
-  }
+  ~MockInputMethodObserver() override {}
 
  private:
-  virtual void OnTextInputTypeChanged(const TextInputClient* client) OVERRIDE {
-  }
-  virtual void OnFocus() OVERRIDE {
-  }
-  virtual void OnBlur() OVERRIDE {
-  }
-  virtual void OnCaretBoundsChanged(const TextInputClient* client) OVERRIDE {
-  }
-  virtual void OnTextInputStateChanged(const TextInputClient* client) OVERRIDE {
+  void OnTextInputTypeChanged(const TextInputClient* client) override {}
+  void OnFocus() override {}
+  void OnBlur() override {}
+  void OnCaretBoundsChanged(const TextInputClient* client) override {}
+  void OnTextInputStateChanged(const TextInputClient* client) override {
     verifier_->OnTextInputStateChanged(client);
   }
-  virtual void OnShowImeIfNeeded() OVERRIDE {
-  }
-  virtual void OnInputMethodDestroyed(const InputMethod* client) OVERRIDE {
-  }
+  void OnShowImeIfNeeded() override {}
+  void OnInputMethodDestroyed(const InputMethod* client) override {}
 
   ClientChangeVerifier* verifier_;
   DISALLOW_COPY_AND_ASSIGN(MockInputMethodObserver);
@@ -227,18 +203,11 @@ class MockTextInputClient : public DummyTextInputClient {
   MockTextInputClient()
       : shown_event_count_(0), updated_event_count_(0), hidden_event_count_(0) {
   }
-  virtual ~MockTextInputClient() {
-  }
+  ~MockTextInputClient() override {}
 
-  virtual void OnCandidateWindowShown() OVERRIDE {
-    ++shown_event_count_;
-  }
-  virtual void OnCandidateWindowUpdated() OVERRIDE {
-    ++updated_event_count_;
-  }
-  virtual void OnCandidateWindowHidden() OVERRIDE {
-    ++hidden_event_count_;
-  }
+  void OnCandidateWindowShown() override { ++shown_event_count_; }
+  void OnCandidateWindowUpdated() override { ++updated_event_count_; }
+  void OnCandidateWindowHidden() override { ++hidden_event_count_; }
 
   int shown_event_count() const { return shown_event_count_; }
   int updated_event_count() const { return updated_event_count_; }