mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 17:30:38 +00:00
Added patches
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@3968 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
eacc77dd95
commit
1ffeed382e
5 changed files with 303 additions and 49 deletions
|
@ -84,18 +84,18 @@ BOOL _fileOwnerDecoded = NO;
|
|||
}
|
||||
else {
|
||||
/* The path is a relative path; search it in the current bundle. */
|
||||
//path = [resourcePath stringByAppendingPathComponent:path];
|
||||
if (![[NSFileManager defaultManager] fileExistsAtPath:
|
||||
[resourcePath stringByAppendingPathComponent:path]]) {
|
||||
NSString *abspath = [resourcePath stringByAppendingPathComponent:path];
|
||||
if (![[NSFileManager defaultManager] fileExistsAtPath:abspath]) {
|
||||
//try in GNUSTEP_ROOT/Library/Model/...
|
||||
NSString *root;
|
||||
|
||||
root = [NSString stringWithCString:getenv("GNUSTEP_SYSTEM_ROOT")];
|
||||
root = [root stringByAppendingPathComponent:@"Library/Model/"];
|
||||
path = [root stringByAppendingPathComponent:path];
|
||||
if (![[NSFileManager defaultManager] fileExistsAtPath:path])
|
||||
abspath = [root stringByAppendingPathComponent:path];
|
||||
if (![[NSFileManager defaultManager] fileExistsAtPath:abspath])
|
||||
return NO;
|
||||
}
|
||||
path = abspath;
|
||||
}
|
||||
|
||||
NSLog (@"loading model file %@...", path);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue