Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 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 BLIMP_CLIENT_CORE_CONTENTS_ANDROID_IME_HELPER_DIALOG_H_ | |
| 6 #define BLIMP_CLIENT_CORE_CONTENTS_ANDROID_IME_HELPER_DIALOG_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "base/android/jni_android.h" | |
| 11 #include "base/macros.h" | |
| 12 #include "blimp/client/core/contents/ime_feature.h" | |
| 13 #include "ui/base/ime/text_input_type.h" | |
| 14 | |
| 15 namespace ui { | |
| 16 class WindowAndroid; | |
| 17 } | |
|
David Trainor- moved to gerrit
2016/08/31 05:59:09
// namespace ui
shaktisahu
2016/08/31 17:28:21
Done.
| |
| 18 | |
| 19 namespace blimp { | |
| 20 namespace client { | |
| 21 | |
| 22 // The native component of | |
| 23 // org.chromium.blimp.core.contents.input.ImeHelperDialog | |
| 24 class ImeHelperDialog : public ImeFeature::Delegate { | |
| 25 public: | |
| 26 static bool RegisterJni(JNIEnv* env); | |
| 27 | |
| 28 explicit ImeHelperDialog(ui::WindowAndroid* window); | |
| 29 ~ImeHelperDialog() override; | |
| 30 | |
| 31 // ImeFeature::Delegate implementation. | |
| 32 void OnShowImeRequested(ui::TextInputType input_type, | |
|
David Trainor- moved to gerrit
2016/08/31 05:59:09
We should look into grouping these params into a R
shaktisahu
2016/08/31 17:28:21
Acknowledged.
| |
| 33 const std::string& text, | |
| 34 const ShowImeCallback& callback) override; | |
| 35 void OnHideImeRequested() override; | |
| 36 | |
| 37 // Sends the text entered from IME to the blimp engine. | |
| 38 void OnImeTextEntered(JNIEnv* env, | |
| 39 const base::android::JavaParamRef<jobject>& jobj, | |
| 40 const base::android::JavaParamRef<jstring>& text); | |
| 41 | |
| 42 private: | |
| 43 base::android::ScopedJavaLocalRef<jobject> java_obj_; | |
| 44 | |
| 45 // A callback to be executed on text submission from the user. | |
| 46 ShowImeCallback textSubmitCallback_; | |
|
David Trainor- moved to gerrit
2016/08/31 05:59:09
text_submit_callback_
shaktisahu
2016/08/31 17:28:21
Done.
| |
| 47 | |
| 48 DISALLOW_COPY_AND_ASSIGN(ImeHelperDialog); | |
| 49 }; | |
| 50 | |
| 51 } // namespace client | |
| 52 } // namespace blimp | |
| 53 #endif // BLIMP_CLIENT_CORE_CONTENTS_ANDROID_IME_HELPER_DIALOG_H_ | |
| OLD | NEW |