summaryrefslogtreecommitdiffstats
path: root/webkit/tools/pepper_test_plugin
diff options
context:
space:
mode:
authorsehr@google.com <sehr@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-09 17:45:03 +0000
committersehr@google.com <sehr@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-09 17:45:03 +0000
commitc2dff4977f8dbd35fd467fb3785587cb634dd190 (patch)
tree5ee05f387a75d856d29895f06f0c64156754c9ff /webkit/tools/pepper_test_plugin
parent5f6397ecb4c7bc92295adc8d21bd87e698ac5622 (diff)
downloadchromium_src-c2dff4977f8dbd35fd467fb3785587cb634dd190.zip
chromium_src-c2dff4977f8dbd35fd467fb3785587cb634dd190.tar.gz
chromium_src-c2dff4977f8dbd35fd467fb3785587cb634dd190.tar.bz2
Revert 34161 - Enable Pepper support by default, including building the test plugin.
This is needed because the NaCl plugin code that runs in the renderer needs to use Pepper APIs all the time, and NaCl support has been enabled by default for several months now. To cause an untrusted Pepper plugin to run in the renderer one needs to specify the internalpepper flag. I have also removed the enable_pepper flag from gyp. As the build of the GPU process was tied to this flag, I have renamed the flag to enable_gpu. TEST=none BUG=none Review URL: http://codereview.chromium.org/464074 TBR=sehr@google.com Review URL: http://codereview.chromium.org/475004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34162 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/tools/pepper_test_plugin')
-rw-r--r--webkit/tools/pepper_test_plugin/README10
-rw-r--r--webkit/tools/pepper_test_plugin/event_handler.cc5
-rw-r--r--webkit/tools/pepper_test_plugin/pepper_test_plugin.gyp3
3 files changed, 13 insertions, 5 deletions
diff --git a/webkit/tools/pepper_test_plugin/README b/webkit/tools/pepper_test_plugin/README
index 4c8003b..96c6397 100644
--- a/webkit/tools/pepper_test_plugin/README
+++ b/webkit/tools/pepper_test_plugin/README
@@ -1,12 +1,18 @@
This is a test plugin for manual testing of the Pepper plugin API. See
https://wiki.mozilla.org/Plugins:PlatformIndependentNPAPI
-Open the Chrome all.sln solution and rebuild the pepper_test_plugin and
+To generate a project from the gyp file, set the GYP_DEFINES environment
+variable to "enable_pepper=1". From a Windows command prompt:
+ set GYP_DEFINES=enable_pepper=1
+
+Then rebuild the project files:
+ gclient runhooks --force
+
+Then open the Chrome all.sln solution and rebuild the pepper_test_plugin and
chrome projects.
To load this plugin in Chrome, use the command line flags:
--no-sandbox
- --internal-pepper
--load-plugin=<<<YOUR CHECKOUT ROOT>>\src\webkit\tools\pepper_test_plugin\Debug\pepper_test_plugin.dll
A simple way to launch Chrome with these command line flags is to run the
diff --git a/webkit/tools/pepper_test_plugin/event_handler.cc b/webkit/tools/pepper_test_plugin/event_handler.cc
index 7884fac..75ede4e 100644
--- a/webkit/tools/pepper_test_plugin/event_handler.cc
+++ b/webkit/tools/pepper_test_plugin/event_handler.cc
@@ -28,7 +28,6 @@
#include <stdio.h>
#include <string>
-#include "base/basictypes.h"
#include "base/logging.h"
#include "base/string_util.h"
#include "webkit/tools/pepper_test_plugin/plugin_object.h"
@@ -128,11 +127,11 @@ int EventHandler::handle(void* event) {
str += StringPrintf(": mod %x, text: ",
npevent->u.character.modifier);
size_t i;
- for (i = 0; i < arraysize(npevent->u.character.text); ++i) {
+ for (i = 0; i < ARRAYSIZE(npevent->u.character.text); ++i) {
str += StringPrintf("%x ", npevent->u.character.text[i]);
}
str += ", unmod: ";
- for (i = 0; i < arraysize(npevent->u.character.unmodifiedText); ++i) {
+ for (i = 0; i < ARRAYSIZE(npevent->u.character.unmodifiedText); ++i) {
str += StringPrintf("%x ", npevent->u.character.unmodifiedText[i]);
}
break;
diff --git a/webkit/tools/pepper_test_plugin/pepper_test_plugin.gyp b/webkit/tools/pepper_test_plugin/pepper_test_plugin.gyp
index 5144e76..a19574e 100644
--- a/webkit/tools/pepper_test_plugin/pepper_test_plugin.gyp
+++ b/webkit/tools/pepper_test_plugin/pepper_test_plugin.gyp
@@ -12,6 +12,9 @@
'include_dirs': [
'../../..', # Root of Chrome Checkout
],
+ 'defines': [
+ 'PEPPER_APIS_ENABLED',
+ ],
'conditions': [
['OS=="win"', {
'product_name': 'pepper_test_plugin',