mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
(main): Use new notification interface.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@1094 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
88ce6294af
commit
6c6372b7f1
1 changed files with 6 additions and 5 deletions
|
@ -21,14 +21,15 @@ int main(int argc, char *argv[])
|
|||
char namebuf[16];
|
||||
|
||||
printf("Looking up server object on localhost with name `secondserver'\n");
|
||||
server = [Connection rootProxyAtName:@"secondserver"];
|
||||
if (argc > 1)
|
||||
server = [Connection rootProxyAtName: [String stringWithCString: argv[1]]];
|
||||
else
|
||||
server = [Connection rootProxyAtName: @"secondserver"];
|
||||
printf("Found server.\n");
|
||||
|
||||
[NotificationDispatcher
|
||||
addObserver: nil
|
||||
invocation: [[[ObjectFunctionInvocation alloc]
|
||||
initWithObjectFunction: announce_new_connection]
|
||||
autorelease]
|
||||
addInvocation: [[ObjectFunctionInvocation alloc]
|
||||
initWithObjectFunction: announce_new_connection]
|
||||
name: ConnectionWasCreatedNotification
|
||||
object: nil];
|
||||
|
||||
|
|
Loading…
Reference in a new issue