-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmainwindow.h
50 lines (38 loc) · 889 Bytes
/
mainwindow.h
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
38
39
40
41
42
43
44
45
46
47
48
49
50
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include<QTimer>
#include <QDialog>
#include<QImage>
#include<QGraphicsView>
#include<QGraphicsScene>
#include<QDebug>
#include"traveller.h"
#include"createnewcustomer.h"
#include"strategy.h"
#define INTERNAL_TIME 1000
namespace Ui {
class MainWindow;
}
class MainWindow : public QDialog
{
Q_OBJECT
public:
explicit MainWindow(QWidget *parent = 0);
~MainWindow();
void addCustomer(Traveller& newCustomer);
//初始化系统时间
void initSystemTime();
//获取系统时间
pair<int,int>& getSystemTime();
public slots:
void create_NewCustomer();
void timeUpDate();
private:
Ui::MainWindow *ui;
QImage *map_image;
vector<Traveller> allCustomers;
QTimer* systemTime;
//当前时间的天数和小时表示
pair<unsigned int,unsigned int> timeDH;
};
#endif // MAINWINDOW_H