next steps serverlist gui
This commit is contained in:
@@ -34,6 +34,7 @@ serverListDialogImpl::serverListDialogImpl(startWindowImpl *sw, QMainWindow *par
|
||||
|
||||
|
||||
connect( buttonBox, SIGNAL( accepted() ), this, SLOT( connectToServer() ));
|
||||
connect( buttonBox, SIGNAL( rejected() ), this, SLOT( closeNetworkClient() ));
|
||||
|
||||
}
|
||||
|
||||
@@ -63,3 +64,8 @@ void serverListDialogImpl::connectToServer()
|
||||
mySw->getSession()->selectServer(item->data(0, Qt::UserRole).toUInt());
|
||||
}
|
||||
}
|
||||
|
||||
void serverListDialogImpl::closeNetworkClient() {
|
||||
|
||||
mySw->getSession()->terminateNetworkClient();
|
||||
}
|
||||
|
||||
@@ -40,6 +40,7 @@ public slots:
|
||||
void clearList();
|
||||
void addServerItem(unsigned);
|
||||
void connectToServer();
|
||||
void closeNetworkClient();
|
||||
|
||||
private:
|
||||
|
||||
|
||||
@@ -122,7 +122,7 @@ startWindowImpl::startWindowImpl(ConfigFile *c)
|
||||
|
||||
connect(this, SIGNAL(signalNetClientServerListShow()), myServerListDialog, SLOT(exec()));
|
||||
connect(this, SIGNAL(signalNetClientServerListClear()), myServerListDialog, SLOT(clearList()));
|
||||
connect(this, SIGNAL(signalNetClientServerListAdd(unsigned serverId)), myServerListDialog, SLOT(addServerItem(serverId)));
|
||||
connect(this, SIGNAL(signalNetClientServerListAdd(unsigned)), myServerListDialog, SLOT(addServerItem(unsigned)));
|
||||
|
||||
connect(this, SIGNAL(signalNetClientSelfJoined(unsigned, QString, int)), myStartNetworkGameDialog, SLOT(joinedNetworkGame(unsigned, QString, int)));
|
||||
connect(this, SIGNAL(signalNetClientPlayerJoined(unsigned, QString, int)), myStartNetworkGameDialog, SLOT(addConnectedPlayer(unsigned, QString, int)));
|
||||
|
||||
Reference in New Issue
Block a user