forked from chntujia/CodfiyAsteriatedGrailClient
-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
37 lines (36 loc) · 792 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
//#define LOBBY
#include <QMetaType>
#include <QtGui>
#include <QApplication>
#include "widget/Animation.h"
#include "widget/RoomView.h"
#include "data/DataInterface.h"
#include "widget/GUI.h"
#include "client/ClientUI.h"
#include "client/Lobby.h"
#include "logic/Logic.h"
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
a.setFont(QFont("simsun", 9));
dataInterface = new DataInterface;
logic = new Logic;
animation = new Animation;
gui = new GUI;
ClientUI c;
#ifdef LOBBY
c.disconnect(&c);
Lobby l;
l.show();
return a.exec();
#else
if(c.exec() == QDialog::Accepted)
{
c.disconnect(&c);
Lobby l;
l.show();
return a.exec();
}
return 0;
#endif
}