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

Unified Diff: ppapi/c/dev/ppb_ime_control_dev.h

Issue 7621010: Never submit: tentative Pepper IME. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: snapshot Created 9 years, 3 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: ppapi/c/dev/ppb_ime_control_dev.h
diff --git a/ppapi/c/dev/ppb_ime_control_dev.h b/ppapi/c/dev/ppb_ime_control_dev.h
new file mode 100644
index 0000000000000000000000000000000000000000..23fe1dc29f6a900f503a71a6baf188c21ba2f7df
--- /dev/null
+++ b/ppapi/c/dev/ppb_ime_control_dev.h
@@ -0,0 +1,44 @@
+/* Copyright (c) 2011 The Chromium Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+#ifndef PPAPI_C_DEV_PPB_IME_CONTROL_DEV_H_
+#define PPAPI_C_DEV_PPB_IME_CONTROL_DEV_H_
+
+#include "ppapi/c/pp_bool.h"
+#include "ppapi/c/pp_completion_callback.h"
+#include "ppapi/c/pp_instance.h"
+#include "ppapi/c/pp_rect.h"
+
+// Intentionally keep sync with WebKit::WebTextInputType defined in:
+// third_party/WebKit/Source/WebKit/chromium/public/WebTextInputType.h
+typedef enum {
+ // Input caret is not in an editable node, no input method shall be used.
+ PP_TEXTINPUT_TYPE_NONE,
+ // Input caret is in a normal editable node, any input method can be used.
+ PP_TEXTINPUT_TYPE_TEXT,
+ // Input caret is in a password box, an input method may be used only if
+ // it's suitable for password input.
+ PP_TEXTINPUT_TYPE_PASSWORD,
+ PP_TEXTINPUT_TYPE_SEARCH,
+ PP_TEXTINPUT_TYPE_EMAIL,
+ PP_TEXTINPUT_TYPE_NUMBER,
+ PP_TEXTINPUT_TYPE_TELEPHONE,
+ PP_TEXTINPUT_TYPE_URL
+} PP_TextInput_Type;
+PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_TextInput_Type, 4);
+
+#define PPB_IMECONTROL_DEV_INTERFACE_0_1 "PPB_IMEControl(Dev);0.1"
+#define PPB_IMECONTROL_DEV_INTERFACE \
+ PPB_IMECONTROL_DEV_INTERFACE_0_1
+
+struct PPB_IMEControl_Dev {
+ void (*SetTextInputType)(PP_Instance instance, PP_TextInput_Type type);
+ void (*UpdateCaretPosition)(PP_Instance instance,
+ PP_Rect caret,
+ PP_Rect boundingBox);
+ void (*ConfirmCompositionText)(PP_Instance instance);
+ void (*CancelCompositionText)(PP_Instance instance);
+};
+
+#endif /* PPAPI_C_DEV_PPB_IME_CONTROL_DEV_H_ */

Powered by Google App Engine
This is Rietveld 408576698