1 // Copyright 2013 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef UI_BASE_IME_DUMMY_INPUT_METHOD_H_ 6 #define UI_BASE_IME_DUMMY_INPUT_METHOD_H_ 7 8 #include "ui/base/ime/input_method.h" 9 10 namespace ui { 11 12 class InputMethodObserver; 13 14 class DummyInputMethod : public InputMethod { 15 public: 16 DummyInputMethod(); 17 virtual ~DummyInputMethod(); 18 19 // InputMethod overrides: 20 virtual void SetDelegate( 21 internal::InputMethodDelegate* delegate) OVERRIDE; 22 virtual void Init(bool focused) OVERRIDE; 23 virtual void OnFocus() OVERRIDE; 24 virtual void OnBlur() OVERRIDE; 25 virtual bool OnUntranslatedIMEMessage( 26 const base::NativeEvent& event, NativeEventResult* result) OVERRIDE; 27 virtual void SetFocusedTextInputClient(TextInputClient* client) OVERRIDE; 28 virtual void DetachTextInputClient(TextInputClient* client) OVERRIDE; 29 virtual TextInputClient* GetTextInputClient() const OVERRIDE; 30 virtual bool DispatchKeyEvent(const ui::KeyEvent& event) OVERRIDE; 31 virtual void OnTextInputTypeChanged(const TextInputClient* client) OVERRIDE; 32 virtual void OnCaretBoundsChanged(const TextInputClient* client) OVERRIDE; 33 virtual void CancelComposition(const TextInputClient* client) OVERRIDE; 34 virtual void OnInputLocaleChanged() OVERRIDE; 35 virtual std::string GetInputLocale() OVERRIDE; 36 virtual bool IsActive() OVERRIDE; 37 virtual TextInputType GetTextInputType() const OVERRIDE; 38 virtual TextInputMode GetTextInputMode() const OVERRIDE; 39 virtual bool CanComposeInline() const OVERRIDE; 40 virtual bool IsCandidatePopupOpen() const OVERRIDE; 41 virtual void ShowImeIfNeeded() OVERRIDE; 42 43 virtual void AddObserver(InputMethodObserver* observer) OVERRIDE; 44 virtual void RemoveObserver(InputMethodObserver* observer) OVERRIDE; 45 46 private: 47 DISALLOW_COPY_AND_ASSIGN(DummyInputMethod); 48 }; 49 50 } // namespace ui 51 52 #endif // UI_BASE_IME_DUMMY_INPUT_METHOD_H_ 53