mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
Implemented allBundles
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@4075 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
05286efbe9
commit
a7f9d28f0d
2 changed files with 20 additions and 1 deletions
|
@ -1,3 +1,8 @@
|
|||
Wed Apr 14 9:10:00 1999 Richard Frith-Macdonald <richard@brainstorm.co.uk>
|
||||
|
||||
* Source/NSBundle: ([+allBundles]) implemented (ignoring the frameworks
|
||||
issue).
|
||||
|
||||
Tue Apr 13 22:05:00 1999 Richard Frith-Macdonald <richard@brainstorm.co.uk>
|
||||
|
||||
* Source/NSBundle.m: Updated to use Info.plist if Info-gnustep.plist
|
||||
|
|
|
@ -267,7 +267,21 @@ _bundle_load_callback(Class theClass, Category *theCategory)
|
|||
|
||||
+ (NSArray *) allBundles
|
||||
{
|
||||
return [self notImplemented: _cmd];
|
||||
NSMapEnumerator enumerate;
|
||||
NSMutableArray *array = [NSMutableArray arrayWithCapacity: 2];
|
||||
void *key;
|
||||
NSBundle *bundle;
|
||||
|
||||
enumerate = NSEnumerateMapTable(_bundles);
|
||||
while (NSNextMapEnumeratorPair(&enumerate, &key, (void **)&bundle))
|
||||
{
|
||||
if ([array indexOfObjectIdenticalTo: bundle] == NSNotFound)
|
||||
{
|
||||
/* FIXME - must ignore frameworks here */
|
||||
[array addObject: bundle];
|
||||
}
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
+ (NSArray *) allFrameworks
|
||||
|
|
Loading…
Reference in a new issue