Добавил:
Studfiles2
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз:
Предмет:
Файл:Курсовая по ООП / qt / interface
.h#ifndef interface_h
#define interface_h
#include <QtGui>
#include <QWidget>
#include "..\classes\shop.h"
#include "..\classes\comm_base.h"
#include "..\classes\saler_base.h"
class gwMainForm: QMainWindow {
Q_OBJECT
private:
gwMainForm() {};
gwMainForm (gwMainForm &a) {};
private:
//Base & Shop
short launchDialog;
Shop *shop;
CommodityDatabase *goodsBase;
SalerDatabase *salersBase;
//Helping widgets & pointers (for topology & other)
QApplication* p;
QTabWidget * Tabs;
QWidget * SalersTab;
QWidget * GoodsTab;
QWidget * ReturnTab;
QWidget * ShopTab;
QGridLayout * SalersLayout;
QGridLayout * GoodsLayout;
QGridLayout * ReturnLayout;
QGridLayout * ShopLayout;
QGridLayout * MainLayout;
QGridLayout * directorLayout;
QTableWidget* GoodsTable;
QTableWidget* SalersTable;
QTableWidget* ReturnTable;
QMessageBox * mess;
QGroupBox * directorBox;
//Line Edits
//------ Man
QLineEdit *firstNameEdit;
QLineEdit *individualTaxNumberEdit;
QLineEdit *lastNameEdit;
QLineEdit *pensionCertificateEdit;
QLineEdit *registrationCertificateEdit;
QLineEdit *telephoneEdit;
//------ Goods
QLineEdit *codeEdit;
QLineEdit *titleEdit;
QLineEdit *supplierEdit;
QLineEdit *priceEdit;
QLineEdit *countEdit;
//------ Information
QLineEdit *sFirstNameEdit;
QLineEdit *sIndividualTaxNumberEdit;
QLineEdit *sLastNameEdit;
QLineEdit *sPensionCertificateEdit;
QLineEdit *sRegistrationCertificateEdit;
QLineEdit *sTelephoneEdit;
QLineEdit *sAddressEdit;
QLineEdit *sSpecializationEdit;
QLineEdit *salersPathEdit;
QLineEdit *goodsPathEdit;
//Labels
//------ Man
QLabel *firstNameLabel;
QLabel *individualTaxNumberLabel;
QLabel *lastNameLabel;
QLabel *pensionCertificateLabel;
QLabel *registrationCertificateLabel;
QLabel *telephoneLabel;
//------ Goods
QLabel *codeLabel;
QLabel *titleLabel;
QLabel *supplierLabel;
QLabel *priceLabel;
QLabel *countLabel;
//------ Information
QLabel *sFirstNameLabel;
QLabel *sIndividualTaxNumberLabel;
QLabel *sLastNameLabel;
QLabel *sPensionCertificateLabel;
QLabel *sRegistrationCertificateLabel;
QLabel *sTelephoneLabel;
QLabel *sAddressLabel;
QLabel *sSpecializationLabel;
QLabel *salersPathLabel;
QLabel *goodsPathLabel;
//Buttons
//------ Goods
QPushButton * delGoodButton;
QPushButton * addGoodButton;
//------ Salers
QPushButton * addSalerButton;
QPushButton * delSalerButton;
//------ Return
QPushButton * makeReturn;
QPushButton * saveReturn;
//------ Information
QPushButton * loadAllButton;
QPushButton * saveAllButton;
QPushButton * saveContactButton;
QPushButton * browseSalersPathButton;
QPushButton * browseGoodsPathButton;
//Dialogs
QFileDialog * openDialog;
//Menu
//------- Main
QMenu *fileMenu;
QMenu *editMenu;
QMenu *helpMenu;
//------- FileTab
QAction *fileSaveBase;
QAction *fileOpenBase;
QAction *fileDoQuit;
//------- EditTab
QAction *editDeleteRecord;
QAction *editNewRecord;
//------- HelpTab
QAction *helpAboutQt;
QAction *helpAbout;
QAction *helpHelp;
void initMenus(void);
void createActions(void);
private slots:
//Save & Load Bases
void saveBase(void);
void openBase(void);
void saveAll(void);
void loadAll(void);
void saveContact(void);
void browseGoodsPath(void);
void browseSalersPath(void);
void addGood(void);
void delCurGood(void);
void addSaler(void);
void delCurSaler(void);
void editedItemGood(int,int);
void editedItemSaler(int,int);
void goodsCountEdit(const QString&);
void editDel(void);
void editAdd(void);
void doQuit(void);
void about(void);
//Return
void doMakeReturn(void);
void doSaveReturn(void);
public slots:
void show(void);
public:
gwMainForm(QApplication &);
virtual ~gwMainForm();
};
#endif
Соседние файлы в папке qt