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

Unified Diff: ppapi/native_client/src/trusted/plugin/plugin.cc

Issue 8815008: Set default text input type to NONE for NaCl apps on OSX (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/native_client/src/trusted/plugin/plugin.cc
diff --git a/ppapi/native_client/src/trusted/plugin/plugin.cc b/ppapi/native_client/src/trusted/plugin/plugin.cc
index 54099071c04704ad0aee1aacb3c6172757584571..ce4ff1814f1d6414c07c84f8bfd36c8e03e22e26 100644
--- a/ppapi/native_client/src/trusted/plugin/plugin.cc
+++ b/ppapi/native_client/src/trusted/plugin/plugin.cc
@@ -67,6 +67,7 @@
#include "ppapi/cpp/dev/printing_dev.h"
#include "ppapi/cpp/dev/scrollbar_dev.h"
#include "ppapi/cpp/dev/selection_dev.h"
+#include "ppapi/cpp/dev/text_input_dev.h"
#include "ppapi/cpp/dev/url_util_dev.h"
#include "ppapi/cpp/dev/widget_client_dev.h"
#include "ppapi/cpp/dev/zoom_dev.h"
@@ -579,6 +580,16 @@ bool Plugin::Init(BrowserInterface* browser_interface,
char* argv[]) {
PLUGIN_PRINTF(("Plugin::Init (instance=%p)\n", static_cast<void*>(this)));
+#ifdef NACL_OSX
+ // TODO(kochi): For crbug.com/102808, this is a stopgap solution for Lion
+ // until we expose IME API to .nexe. This disables any IME interference
+ // against key inputs, so you cannot use off-the-spot IME input for NaCl apps.
+ // This makes discrepancy among platforms and therefore we should remove
+ // this hack when IME API is made available.
+ // The default for non-Mac platforms is still off-the-spot IME mode.
+ pp::TextInput_Dev(this).SetTextInputType(PP_TEXTINPUT_TYPE_NONE);
+#endif
+
browser_interface_ = browser_interface;
// Remember the embed/object argn/argv pairs.
argn_ = new(std::nothrow) char*[argc];
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698