mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-30 16:30:41 +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
709528e09d
commit
653e2f63f9
1 changed files with 6 additions and 5 deletions
|
@ -21,14 +21,15 @@ int main(int argc, char *argv[])
|
||||||
char namebuf[16];
|
char namebuf[16];
|
||||||
|
|
||||||
printf("Looking up server object on localhost with name `secondserver'\n");
|
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");
|
printf("Found server.\n");
|
||||||
|
|
||||||
[NotificationDispatcher
|
[NotificationDispatcher
|
||||||
addObserver: nil
|
addInvocation: [[ObjectFunctionInvocation alloc]
|
||||||
invocation: [[[ObjectFunctionInvocation alloc]
|
initWithObjectFunction: announce_new_connection]
|
||||||
initWithObjectFunction: announce_new_connection]
|
|
||||||
autorelease]
|
|
||||||
name: ConnectionWasCreatedNotification
|
name: ConnectionWasCreatedNotification
|
||||||
object: nil];
|
object: nil];
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue