mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 23:31:02 +00:00
Fixed [NSProcessInfo -processName] and updated places that used it.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@4809 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
989462d2f7
commit
95d6f663cf
2 changed files with 7 additions and 19 deletions
|
@ -192,7 +192,7 @@ NSRegisterServicesProvider(id provider, NSString *name)
|
|||
|
||||
if (servicesProvider != anObject)
|
||||
{
|
||||
appName = [[[NSProcessInfo processInfo] processName] lastPathComponent];
|
||||
appName = [[NSProcessInfo processInfo] processName];
|
||||
NSRegisterServicesProvider(anObject, appName);
|
||||
}
|
||||
}
|
||||
|
@ -391,7 +391,7 @@ static NSString *disabledName = @".GNUstepDisabled";
|
|||
{
|
||||
NSString *appName;
|
||||
|
||||
appName = [[[NSProcessInfo processInfo] processName] lastPathComponent];
|
||||
appName = [[NSProcessInfo processInfo] processName];
|
||||
[timer invalidate];
|
||||
NSUnregisterServicesProvider(appName);
|
||||
[languages release];
|
||||
|
@ -825,7 +825,7 @@ static NSString *disabledName = @".GNUstepDisabled";
|
|||
NSString *appName;
|
||||
BOOL registered;
|
||||
|
||||
appName = [[[NSProcessInfo processInfo] processName] lastPathComponent];
|
||||
appName = [[NSProcessInfo processInfo] processName];
|
||||
NS_DURING
|
||||
{
|
||||
NSRegisterServicesProvider(self, appName);
|
||||
|
|
|
@ -211,27 +211,16 @@ NSApplication *NSApp = nil;
|
|||
* Now check to see if we were launched with arguments asking to
|
||||
* open a file. We permit some variations on the default name.
|
||||
*/
|
||||
filePath = [defs stringForKey: @"-GSFilePath"];
|
||||
if (filePath == nil)
|
||||
filePath = [defs stringForKey: @"--GSFilePath"];
|
||||
if (filePath == nil)
|
||||
filePath = [defs stringForKey: @"GSFilePath"];
|
||||
if (filePath != nil)
|
||||
if ((filePath = [defs stringForKey: @"GSFilePath"]) != nil)
|
||||
{
|
||||
if ([delegate respondsToSelector: @selector(application:openFile:)])
|
||||
{
|
||||
[delegate application: self openFile: filePath];
|
||||
}
|
||||
}
|
||||
else
|
||||
else if ((filePath = [defs stringForKey: @"GSTempPath"]) != nil)
|
||||
{
|
||||
filePath = [defs stringForKey: @"-GSTempPath"];
|
||||
if (filePath == nil)
|
||||
filePath = [defs stringForKey: @"--GSTempPath"];
|
||||
if (filePath == nil)
|
||||
filePath = [defs stringForKey: @"GSTempPath"];
|
||||
if (filePath != nil
|
||||
&& [delegate respondsToSelector: @selector(application:openTempFile:)])
|
||||
if ([delegate respondsToSelector: @selector(application:openTempFile:)])
|
||||
{
|
||||
[delegate application: self openTempFile: filePath];
|
||||
}
|
||||
|
@ -1114,8 +1103,7 @@ NSAssert([event retainCount] > 0, NSInternalInconsistencyException);
|
|||
|
||||
ASSIGN(main_menu, aMenu);
|
||||
|
||||
[main_menu setTitle:
|
||||
[[[NSProcessInfo processInfo] processName] lastPathComponent]];
|
||||
[main_menu setTitle: [[NSProcessInfo processInfo] processName]];
|
||||
[main_menu sizeToFit];
|
||||
/*
|
||||
* Find a menucell with the title Windows this is the default windows menu
|
||||
|
|
Loading…
Reference in a new issue