Moving part of fix for #81659 from 0.9.2 branch. Now recognize non-bundle OS X plugins of type 'IEPL' (e.g. Apple's iTools plugin). Also moved test for OS X plugin types inside an #if TARGET_CARBON.

This commit is contained in:
sdagley%netscape.com 2001-07-25 02:45:10 +00:00
Родитель 52f4ef75ac
Коммит 77bb0393b7
2 изменённых файлов: 10 добавлений и 2 удалений

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

@ -140,10 +140,14 @@ PRBool nsPluginsDir::IsPluginFile(const nsFileSpec& fileSpec)
const FSSpec& spec = fileSpec; const FSSpec& spec = fileSpec;
OSErr result = FSpGetFInfo(&spec, &info); OSErr result = FSpGetFInfo(&spec, &info);
if (result == noErr && ((info.fdType == 'shlb' && info.fdCreator == 'MOSS') || if (result == noErr && ((info.fdType == 'shlb' && info.fdCreator == 'MOSS') ||
info.fdType == 'NSPL' || info.fdType == 'BRPL')) info.fdType == 'NSPL'))
return PR_TRUE; return PR_TRUE;
#if TARGET_CARBON #if TARGET_CARBON
// Some additional plugin types for Carbon/Mac OS X
if (result == noErr && (info.fdType == 'BRPL' || info.fdType == 'IEPL'))
return PR_TRUE;
// for Mac OS X bundles. // for Mac OS X bundles.
CFBundleRef bundle = getPluginBundle(spec); CFBundleRef bundle = getPluginBundle(spec);
if (bundle) { if (bundle) {

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

@ -140,10 +140,14 @@ PRBool nsPluginsDir::IsPluginFile(const nsFileSpec& fileSpec)
const FSSpec& spec = fileSpec; const FSSpec& spec = fileSpec;
OSErr result = FSpGetFInfo(&spec, &info); OSErr result = FSpGetFInfo(&spec, &info);
if (result == noErr && ((info.fdType == 'shlb' && info.fdCreator == 'MOSS') || if (result == noErr && ((info.fdType == 'shlb' && info.fdCreator == 'MOSS') ||
info.fdType == 'NSPL' || info.fdType == 'BRPL')) info.fdType == 'NSPL'))
return PR_TRUE; return PR_TRUE;
#if TARGET_CARBON #if TARGET_CARBON
// Some additional plugin types for Carbon/Mac OS X
if (result == noErr && (info.fdType == 'BRPL' || info.fdType == 'IEPL'))
return PR_TRUE;
// for Mac OS X bundles. // for Mac OS X bundles.
CFBundleRef bundle = getPluginBundle(spec); CFBundleRef bundle = getPluginBundle(spec);
if (bundle) { if (bundle) {