source: src-qt4/EasyPBI/mainGUI.h @ ebba654

releng/10.0releng/10.0.1releng/10.0.2
Last change on this file since ebba654 was ebba654, checked in by Ken Moore <ken@…>, 8 months ago

Move over the EasyPBI-devel to src-qt4/EasyPBI

  • Property mode set to 100644
File size: 3.2 KB
Line 
1#ifndef MAINGUI_H
2#define MAINGUI_H
3
4#include <QMainWindow>
5#include <QFileDialog>
6#include <QInputDialog>
7#include <QMessageBox>
8#include <QString>
9#include <QDir>
10#include <QProcess>
11#include <QTimer>
12#include <QDateTime>
13#include <QRadioButton>
14#include <QMenu>
15#include <QFileDialog>
16#include <QTreeWidget>
17#include <QTreeWidgetItem>
18
19#include "backend.h"
20#include "config.h"
21#include "PBIModule.h"
22#include "ModuleUtils.h"
23#include "pkgSelect.h"
24
25namespace Ui {
26    class MainGUI;
27}
28
29class MainGUI : public QMainWindow
30{
31    Q_OBJECT
32
33public:
34    explicit MainGUI(QWidget *parent = 0);
35    ~MainGUI();
36
37    void loadModule(QString confFile);
38
39private slots:
40    //general purpose functions
41    void slotSingleInstance();
42    void refreshGUI(QString);
43    //menubar functions
44    void on_actionExit_triggered();
45    void on_actionNew_Module_triggered();
46    void on_actionLoad_Module_triggered();
47    void on_actionPreferences_triggered();
48    void on_actionPackage_Module_triggered();
49    void on_actionRefresh_Module_triggered();
50    void on_actionFreeBSD_Ports_triggered();
51    void on_actionPBI_Modules_triggered();
52    void on_actionAbout_EasyPBI_triggered();
53    //editor functions
54    void updateConfigVisibility();
55    void slotModTabChanged(int);
56    //pbi.conf functions
57    void on_push_change_makeport_clicked();
58    void on_push_addportafter_clicked();
59    void on_push_rmportafter_clicked();
60    void on_push_config_save_clicked();
61    void slotOptionChanged(QString tmp="");
62    void slotSetRepoType(QAction* act);
63    void slotSetRepoCat(QAction* act);
64    //resources functions
65    void slotResourceChanged();
66    void on_push_resources_add_clicked();
67    void on_push_resources_remove_clicked();
68    void on_push_resources_mkwrapper_clicked();
69    void slotResourceScriptSaved();
70    void slotResourceScriptChanged();
71    //XDG functions
72    void slotXdgTypeChanged();
73    void slotXdgFileChanged();
74    void slotAddMenuCat(QAction*);
75    void slotAddBin(QAction*);
76    void on_push_xdg_remove_clicked();
77    void on_push_xdg_savechanges_clicked();
78    void on_push_xdg_savenew_clicked();
79    void on_push_xdg_clearentry_clicked();
80    void slotXDGOptionChanged(QString tmp="");
81    //Scripts functions
82    void slotScriptChanged(int);
83    void on_push_scripts_create_clicked();
84    void on_push_scripts_remove_clicked();
85    void on_push_scripts_save_clicked();
86    void slotScriptModified();
87    //External-Links functions
88    void on_push_el_add_clicked();
89    void on_push_el_remove_clicked();
90    void slotELSetFile(QAction*);
91    void slotELSetType(QAction*);
92    //PBI Build functions
93    void on_push_build_start_clicked();
94    void on_push_build_stop_clicked();
95    void on_push_build_save_clicked();
96    void slotUpdatePBIBuild();
97    void slotPBIbuildFinished(int,QProcess::ExitStatus);
98    void slotKillPBIBuild();
99    void slotBuildError(QProcess::ProcessError);
100
101
102private:
103    Ui::MainGUI *ui;
104    PBIModule MODULE;
105    Config *settings;
106    QLineEdit *line_module;
107    QMenu menu_elOpts, menu_validMenuCats, menu_validRepoCats, menu_validRepoTypes;
108    bool XDGUPDATING;
109    QString lastModuleDir;
110
111    QString PBI_BUILDING_NOW;
112    bool PBI_BUILD_TERMINATED;
113    QProcess *p;
114
115    void SetupDefaults();
116    void checkMime();
117
118};
119
120#endif // MAINGUI_H
Note: See TracBrowser for help on using the repository browser.