#import <ObjXMPP/ObjXMPP.h>
#import "JubGtkUI.h"
+#import "JubConfig.h"
@interface AppDelegate: OFObject
<OFApplicationDelegate, XMPPConnectionDelegate, XMPPRosterDelegate>
- (void)applicationDidFinishLaunching
{
id<XMPPRosterDelegate, XMPPConnectionDelegate> rosterDelegate;
+ JubConfig *config = [[JubConfig alloc] initWithFile: @"config.xml"];
connection = [[XMPPConnection alloc] init];
[connection addDelegate: self];
- connection.domain = @"localhost";
- connection.username = @"alice";
- connection.password = @"test";
+ connection.domain = config.domain;
+ connection.server = config.server;
+ connection.username = config.username;
+ connection.password = config.password;
ui = [[JubGtkUI alloc] initWithConnection: connection];
rosterDelegate = [ui rosterDelegate];