Fix plugin loading from framework

This commit is contained in:
Gregory John Casamento 2023-06-12 03:50:05 -04:00
parent 59775174d7
commit 9e5e9f8c04
2 changed files with 3 additions and 6 deletions

View file

@ -79,10 +79,6 @@ Gorm_RESOURCE_FILES = \
Palettes/2Controls/2Controls.palette \
Palettes/3Containers/3Containers.palette \
Palettes/4Data/4Data.palette \
Plugins/Gorm/Gorm.plugin \
Plugins/Nib/Nib.plugin \
Plugins/GModel/GModel.plugin \
Plugins/Xib/Xib.plugin \
Images/GormClass.tiff \
Images/GormFilesOwner.tiff \
Images/GormFirstResponder.tiff \

View file

@ -51,6 +51,7 @@
NSArray *array;
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSArray *userPlugins = [defaults arrayForKey: USER_PLUGINS];
NSBundle *bundle = [NSBundle bundleForClass: [self class]];
self = [super init];
if (self == nil)
@ -65,8 +66,8 @@
plugins = [[NSMutableArray alloc] init];
pluginNames = [[NSMutableArray alloc] init];
array = [[NSBundle mainBundle] pathsForResourcesOfType: @"plugin"
inDirectory: nil];
array = [bundle pathsForResourcesOfType: @"plugin"
inDirectory: nil];
if ([array count] > 0)
{
unsigned index;