mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-02 01:48:05 +00:00
Don't allow plugin to set NPPVpluginWindowBool on OS X. b=466495 r=josh sr=roc
This commit is contained in:
parent
e3d671ca8a
commit
6fac290294
@ -2110,8 +2110,16 @@ _setvalue(NPP npp, NPPVariable variable, void *result)
|
|||||||
// actual pointer value is checked rather than its content
|
// actual pointer value is checked rather than its content
|
||||||
// when passing booleans
|
// when passing booleans
|
||||||
case NPPVpluginWindowBool: {
|
case NPPVpluginWindowBool: {
|
||||||
|
#ifdef XP_MACOSX
|
||||||
|
// This setting doesn't apply to OS X (only to Windows and Unix/Linux).
|
||||||
|
// See https://developer.mozilla.org/En/NPN_SetValue#section_5. Return
|
||||||
|
// NPERR_NO_ERROR here to conform to other browsers' behavior on OS X
|
||||||
|
// (e.g. Safari and Opera).
|
||||||
|
return NPERR_NO_ERROR;
|
||||||
|
#else
|
||||||
NPBool bWindowless = (result == nsnull);
|
NPBool bWindowless = (result == nsnull);
|
||||||
return inst->SetWindowless(bWindowless);
|
return inst->SetWindowless(bWindowless);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
case NPPVpluginTransparentBool: {
|
case NPPVpluginTransparentBool: {
|
||||||
|
Loading…
Reference in New Issue
Block a user