mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 01:00:38 +00:00
Fixes for better workspace notification and to allow shutdown of an app
by an external process. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@21784 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
bd8fb5fc53
commit
b5c8c6000c
3 changed files with 57 additions and 7 deletions
|
@ -83,6 +83,7 @@ static NSString *GSWorkspaceNotification = @"GSWorkspaceNotification";
|
|||
NSDistributedNotificationCenter *remote;
|
||||
}
|
||||
- (void) _handleRemoteNotification: (NSNotification*)aNotification;
|
||||
- (void) _postLocal: (NSString*)name userInfo: (NSDictionary*)info;
|
||||
@end
|
||||
|
||||
@implementation _GSWorkspaceCenter
|
||||
|
@ -181,9 +182,22 @@ static NSString *GSWorkspaceNotification = @"GSWorkspaceNotification";
|
|||
*/
|
||||
- (void) _handleRemoteNotification: (NSNotification*)aNotification
|
||||
{
|
||||
[super postNotification: aNotification];
|
||||
[self _postLocal: [aNotification name]
|
||||
userInfo: [aNotification userInfo]];
|
||||
}
|
||||
|
||||
/*
|
||||
* Method allowing a notification to be posted locally.
|
||||
*/
|
||||
- (void) _postLocal: (NSString*)name userInfo: (NSDictionary*)info
|
||||
{
|
||||
NSNotification *aNotification;
|
||||
|
||||
aNotification = [NSNotification notificationWithName: name
|
||||
object: self
|
||||
userInfo: info];
|
||||
[super postNotification: aNotification];
|
||||
}
|
||||
@end
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue