Modified plugin logic so one class can be multiple plugin types.

CQTexperiment
vspader 2009-02-28 20:12:47 -08:00
parent b5b5b45eda
commit d7ddda160e
1 changed files with 4 additions and 7 deletions

View File

@ -71,21 +71,18 @@ static PluginController *sharedPluginController = nil;
if ([bundleClass conformsToProtocol:@protocol(CogContainer)]) {
[self setupContainer:className];
}
else if ([bundleClass conformsToProtocol:@protocol(CogDecoder)]) {
if ([bundleClass conformsToProtocol:@protocol(CogDecoder)]) {
[self setupDecoder:className];
}
else if ([bundleClass conformsToProtocol:@protocol(CogMetadataReader)]) {
if ([bundleClass conformsToProtocol:@protocol(CogMetadataReader)]) {
[self setupMetadataReader:className];
}
else if ([bundleClass conformsToProtocol:@protocol(CogPropertiesReader)]) {
if ([bundleClass conformsToProtocol:@protocol(CogPropertiesReader)]) {
[self setupPropertiesReader:className];
}
else if ([bundleClass conformsToProtocol:@protocol(CogSource)]) {
if ([bundleClass conformsToProtocol:@protocol(CogSource)]) {
[self setupSource:className];
}
else {
NSLog(@"Unknown plugin type!!");
}
}
}