source: src-qt4/pc-updategui/mainWin.h

Last change on this file was babf972, checked in by yurkis <yurkis@…>, 4 weeks ago

UpdateGUI: Added dialog with system update descriptions. Ported from Update Center. Feature #5875

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