source: src-qt4/pc-softwaremanager/processManager.h @ 74c359f

9.2-releasereleng/10.0releng/10.0.1
Last change on this file since 74c359f was 74c359f, checked in by Ken Moore <ken@…>, 9 months ago

Setup the AppCafe? so that the status displayed in the treewidget is a short status, with the full status at the bottom of the info group if selected. This status shows not only the current download percent and rate, but also any install/remove/update status notifications as they happen.

  • Property mode set to 100644
File size: 1.1 KB
Line 
1#ifndef _APPCAFE_PROCESS_MANAGER_H
2#define _APPCAFE_PROCESS_MANAGER_H
3
4#include <QProcess>
5#include <QProcessEnvironment>
6#include <QString>
7#include <QStringList>
8#include <QObject>
9#include <QDebug>
10
11#include "extras.h"
12       
13class ProcessManager : public QObject
14{
15        Q_OBJECT
16public:
17        enum ProcessID{ ALL, UPDATE, REMOVE, DOWNLOAD, INSTALL, OTHER };
18       
19        ProcessManager();
20        ~ProcessManager();
21       
22        void goToDirectory(ProcessID, QString);
23       
24        void startProcess(ProcessID, QString);
25        void stopProcess(ProcessID);
26        QStringList getProcessLog(ProcessID);
27       
28signals:
29        void ProcessFinished(int ID);
30        void ProcessMessage(int ID,QString);
31        void ProcessError(int ID,QStringList);
32       
33private:
34        QProcess *upProc, *remProc, *dlProc, *inProc, *otProc;
35        QStringList upLog, remLog, dlLog, inLog;
36
37private slots:
38        QString parseDlLine(QString);
39        void slotUpProcMessage();
40        void slotUpProcFinished();
41        void slotRemProcMessage();
42        void slotRemProcFinished();
43        void slotDlProcMessage();
44        void slotDlProcFinished();
45        void slotInProcMessage();
46        void slotInProcFinished();
47        void slotOtProcMessage();
48        void slotOtProcFinished();
49
50};
51
52#endif
Note: See TracBrowser for help on using the repository browser.