Bug 1461243 - Part 3: Remove unused Java `codebase` check from nptest plugin. r=jimm

MozReview-Commit-ID: 7BHECmnqbsz

--HG--
extra : rebase_source : dfd25a3968d64e9fa52cd27b27db5eca7cffb74c
extra : intermediate-source : 81f870f0e92fb1be29c6579c1b02b56db2e0f409
extra : source : a9f1daca4e61261dc437dabd984a36cea79a327c
This commit is contained in:
Chris Peterson 2018-02-19 15:05:32 -08:00
Родитель 94658984be
Коммит e5986134d4
2 изменённых файлов: 0 добавлений и 23 удалений

Просмотреть файл

@ -135,7 +135,6 @@ static bool setPluginWantsAllStreams(NPObject* npobj, const NPVariant* args, uin
static bool crashPlugin(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result);
static bool crashOnDestroy(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result);
static bool getObjectValue(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result);
static bool getJavaCodebase(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result);
static bool checkObjectValue(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result);
static bool enableFPExceptions(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result);
static bool hangPlugin(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result);
@ -207,7 +206,6 @@ static const NPUTF8* sPluginMethodIdentifierNames[] = {
"crash",
"crashOnDestroy",
"getObjectValue",
"getJavaCodebase",
"checkObjectValue",
"enableFPExceptions",
"hang",
@ -280,7 +278,6 @@ static const ScriptableFunction sPluginMethodFunctions[] = {
crashPlugin,
crashOnDestroy,
getObjectValue,
getJavaCodebase,
checkObjectValue,
enableFPExceptions,
hangPlugin,
@ -882,11 +879,6 @@ NPP_New(NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, char*
if (strcmp(argn[i], "bugmode") == 0) {
instanceData->bugMode = atoi(argv[i]);
}
// Try to emulate java's codebase handling: Use the last seen codebase
// value, regardless of whether it is in attributes or params.
if (strcasecmp(argn[i], "codebase") == 0) {
instanceData->javaCodebase = argv[i];
}
// Bug 1307694 - There are two flash parameters that are order dependent for
// scaling/sizing the plugin. If they ever change from what is expected, it
@ -2724,20 +2716,6 @@ static const NPClass kTestSharedNPClass = {
// Everything else is nullptr
};
static bool getJavaCodebase(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result)
{
if (argCount != 0) {
return false;
}
NPP npp = static_cast<TestNPObject*>(npobj)->npp;
InstanceData* id = static_cast<InstanceData*>(npp->pdata);
char *outval = NPN_StrDup(id->javaCodebase.c_str());
STRINGZ_TO_NPVARIANT(outval, *result);
return true;
}
static bool getObjectValue(NPObject* npobj, const NPVariant* args, uint32_t argCount, NPVariant* result)
{
NPP npp = static_cast<TestNPObject*>(npobj)->npp;

Просмотреть файл

@ -141,7 +141,6 @@ typedef struct InstanceData {
bool wantsAllStreams;
int32_t mouseUpEventCount;
int32_t bugMode;
std::string javaCodebase;
AsyncDrawing asyncDrawing;
NPAsyncSurface *frontBuffer;
NPAsyncSurface *backBuffer;