diff options
author | nona@chromium.org <nona@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-19 09:15:20 +0000 |
---|---|---|
committer | nona@chromium.org <nona@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-19 09:15:20 +0000 |
commit | 324cddefbd49b2743f92fb8d1cdccdc7b13c0211 (patch) | |
tree | 99af84d32246e33c2c34c46400063100346a8381 /chromeos | |
parent | 429b5716df0a6312b911474b1db20e428a17b9ec (diff) | |
download | chromium_src-324cddefbd49b2743f92fb8d1cdccdc7b13c0211.zip chromium_src-324cddefbd49b2743f92fb8d1cdccdc7b13c0211.tar.gz chromium_src-324cddefbd49b2743f92fb8d1cdccdc7b13c0211.tar.bz2 |
Move GetFallbackInputMethodDescriptor function to InputMethodUtil.
I think this function should be in InputMethodUtil rather than in InputMethodDescriptors.
Let me clean up InputMethodDescriptor before starting refactoring.
BUG=164375
TEST=None, ran unit_tests.
Review URL: https://chromiumcodereview.appspot.com/13954012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@195121 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chromeos')
-rw-r--r-- | chromeos/ime/input_method_descriptor.cc | 26 | ||||
-rw-r--r-- | chromeos/ime/input_method_descriptor.h | 8 |
2 files changed, 0 insertions, 34 deletions
diff --git a/chromeos/ime/input_method_descriptor.cc b/chromeos/ime/input_method_descriptor.cc index 3ed8da3..408852c 100644 --- a/chromeos/ime/input_method_descriptor.cc +++ b/chromeos/ime/input_method_descriptor.cc @@ -12,10 +12,6 @@ namespace chromeos { namespace input_method { -namespace { -const char kFallbackLayout[] = "us"; -} // namespace - InputMethodDescriptor::InputMethodDescriptor( const std::string& id, const std::string& name, @@ -47,27 +43,5 @@ bool InputMethodDescriptor::operator!=( return !(*this == other); } -// static -InputMethodDescriptor -InputMethodDescriptor::GetFallbackInputMethodDescriptor() { - return InputMethodDescriptor("xkb:us::eng", - "", - kFallbackLayout, - "en-US", - "", // options page, not available. - false); -} - -std::string InputMethodDescriptor::ToString() const { - std::stringstream stream; - stream << "id=" << id() - << ", name=" << name() - << ", keyboard_layout=" << keyboard_layout() - << ", language_code=" << language_code() - << ", options_page_url=" << options_page_url() - << ", third_party=" << third_party(); - return stream.str(); -} - } // namespace input_method } // namespace chromeos diff --git a/chromeos/ime/input_method_descriptor.h b/chromeos/ime/input_method_descriptor.h index 3717411..39a0d20 100644 --- a/chromeos/ime/input_method_descriptor.h +++ b/chromeos/ime/input_method_descriptor.h @@ -31,9 +31,6 @@ class CHROMEOS_EXPORT InputMethodDescriptor { bool operator==(const InputMethodDescriptor& other) const; bool operator!=(const InputMethodDescriptor& other) const; - // Debug print function. - std::string ToString() const; - const std::string& id() const { return id_; } const std::string& name() const { return name_; } const std::string& keyboard_layout() const { return keyboard_layout_; } @@ -41,11 +38,6 @@ class CHROMEOS_EXPORT InputMethodDescriptor { const std::string& options_page_url() const { return options_page_url_; } bool third_party() const { return third_party_; } - // Returns the fallback input method descriptor (the very basic US - // keyboard). This function is mostly used for testing, but may be used - // as the fallback, when there is no other choice. - static InputMethodDescriptor GetFallbackInputMethodDescriptor(); - private: // An ID that identifies an input method engine (e.g., "t:latn-post", // "pinyin", "hangul"). |