APservice/win10_pay.h

106 lines
2.4 KiB
C
Raw Normal View History

2023-11-14 09:32:56 +01:00
#ifndef WIN10_PAY_H
#define WIN10_PAY_H
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QGridLayout>
#include <QObject>
#include <QTimer>
#include <QDebug>
#include <QScrollBar>
#include <QPlainTextEdit>
#include <QComboBox>
#include <QLabel>
#include <QScrollArea>
#include <QSerialPortInfo>
#include <QWidget>
#include <QListWidget>
#include <QGroupBox>
#include <QPushButton>
#include <QRadioButton>
#include <QLineEdit>
#include "tslib.h"
#include "stepList.h"
#include "plugin.h"
#include "keypad.h"
#include "guidefs.h"
class T_win10 : public QWidget
{
Q_OBJECT
QGridLayout *myLayout;
hwinf *HWaccess;
uint16_t myNextStep;
uint8_t myStep;
QLabel *lab1;
QLabel *lab2;
QLabel *lab3;
QLabel *lab4;
QLabel *lab5;
QLabel *lab6;
QLabel *lab7;
QLabel *lab8;
QLabel *lab9;
QTimer *myTO;
QTimer *timerClrDisp;
QLineEdit *startAmount;
QLineEdit *insertedTotal;
QLineEdit *insertedCoin;
QLineEdit *coinPayState;
QLineEdit *coinPaySignals;
QListWidget *allCoins;
QPushButton *pb_statPay;
QPushButton *pb_stopPay;
QPushButton *pb_cancelPay;
QPushButton *pb_vendSucc;
QPushButton *pb_vendFail;
QListWidget *empState;
QGroupBox *numPad;
//void drawNumPad(void);
QPushButton *pb_enterPrice;
T_keypad *myKeypad;
public:
explicit T_win10(hwinf *HWaccess = nullptr, QWidget *parent = nullptr);
bool work_ini(uint16_t *nextScreen, uint8_t *useNavi);
// useNavi=0: no change
// bit0,1: enable/disable button "next"
// bit2,3: enable/disable button "home"
// bit4,5: enable/disable button "back"
bool working (uint16_t *nextScreen, uint8_t *useNavi);
~T_win10();
private slots:
void Nav_back(void);
void Nav_home(void);
void Nav_next(void);
void ButtonStartClicked();
void ButtonStopClicked();
void ButtonCancelClicked();
void ButtonSuccClicked();
void ButtonFailClicked();
void signalGotNewCoin();
void signalJustStarted();
void signalCollectAbort();
void signalStopByMax();
void signalStopByUser();
void signalStopByEscrow();
void signalStopByError();
void signalStopTO() ;
void signalCancelled() ;
void signalProcessStop();
void win10_slotClrSig();
void addDigit2Val(uint8_t digi);
void Button_enterPriceClicked(void);
void valueIsSet(void);
void pay_slotClrSig(void);
};
#endif