source: src-qt4/pc-pkgmanager/mainWin.h @ 3f4caf6

9.1-release9.2-releasereleng/10.0releng/10.0.1
Last change on this file since 3f4caf6 was 3f4caf6, checked in by Kris Moore <kris@…>, 12 months ago

Add the beginnings of our new pc-pkgmanager GUI utility

  • Property mode set to 100644
File size: 1.3 KB
Line 
1#ifndef MAINWIN_H
2#define MAINWIN_H
3
4#include <QDialog>
5#include <QFile>
6#include <QMenu>
7#include <QMessageBox>
8#include <QProcess>
9#include <QProgressDialog>
10#include <QSocketNotifier>
11#include <QStringList>
12#include <QTextStream>
13#include <QTimer>
14
15#include <pcbsd-utils.h>
16#include "ui_mainWin.h"
17#include "../config.h"
18
19/* Change this to switch the default patch tmpdir */
20const QString PATCHTMPDIR_DEFAULT( PREFIX + "/tmp" );
21#define SYSTRIGGER "/tmp/.sysupdatetraytrigger"
22
23class mainWin : public QDialog, private Ui::mainWin
24{
25        Q_OBJECT
26
27public:
28        mainWin() : QDialog()
29        {
30          setupUi(this);
31        }
32
33    QMap <QString, QString> codeMap;
34
35public slots:
36    void ProgramInit(QString, QString);
37    void slotSingleInstance();
38
39private slots:
40    void slotCloseClicked();
41
42    // Package updates
43    void slotRescanPkgsClicked();
44    void slotUpdatePkgsClicked();
45    void slotReadPkgUpdateOutput();
46    void slotUpdatePkgDone();
47    void slotReadEventPipe(int fd);
48
49private:
50    void doUpdates();
51    bool sanityCheck();
52    void checkMPKGUpdates();
53    int curUpdate;
54    int curUpdateIndex;
55    int totUpdate;
56    bool dPackages;
57    bool uPackages;
58    bool doingUpdate;
59    QProcess *uProc;
60    QList<QStringList> listUpdates;
61    QString wDir, wIP;
62    QString lastError;
63    QSocketNotifier *eSock;
64
65signals:
66
67} ;
68#endif // MAINWIN_H
69
Note: See TracBrowser for help on using the repository browser.