-
Notifications
You must be signed in to change notification settings - Fork 0
/
widget.h
63 lines (55 loc) · 1.36 KB
/
widget.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
51
52
53
54
55
56
57
58
59
60
61
62
63
#ifndef WIDGET_H
#define WIDGET_H
#include <QWidget>
#include <QGraphicsView>
#include <QPixmap>
#include <QLabel>
#include <QTextEdit>
#include <QPushButton>
#include <QLineEdit>
#include "bbQueue.h"
#include "customer.h"
#include "teller.h"
#include <cstdlib>
#include <ctime>
#include <algorithm>
#include <QTimer>
#include <QLCDNumber>
namespace Ui {
class Widget;
}
class Widget : public QWidget
{
Q_OBJECT
public:
explicit Widget(QWidget *parent = 0);
~Widget();
private slots:
void startClicked();
void startSim();
void setGUI();
private:
Ui::Widget *ui;
QLineEdit *iobox[10];
QPushButton *button;
QLabel *label[10];
QGraphicsScene *scnHappy;
QGraphicsScene *scnSad;
QGraphicsScene *scnIndiff;
QGraphicsScene *scnTeller;
QGraphicsScene *scnBlank;
QGraphicsScene *scnBreak;
QGraphicsView *fBank[14][10];
QGraphicsView *sBank[14][10];
QLCDNumber *clock;
int cNum, tNum, curTime, totalCustomer, totalCustomerSB, totalWaitTime, totalWaitTimeSB,
totalCustomerLost, totalCustomerLostSB, numberOfLineJumps, leavingI,
leavingJ, SBLeavingI, SBLeavingJ, wonOvers;
teller *fbTeller, *sbTeller;
bbQueue *fbLine, sbLine;
customer *endOfTheLine;
void enterQ(customer c = customer());
void SBEnterQ(customer c = customer());
bool shortestLine(int &s);
};
#endif // WIDGET_H