summaryrefslogtreecommitdiff
path: root/noncore/unsupported/oipkg/pmipkg.h
blob: 8e06f4cf0783c1c2e4783b732a8892e3bf49136e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#ifndef PMIPKG_H
#define PMIPKG_H


#include <qobject.h>
#include <qlist.h>
#include <qstring.h>
#include <qwidget.h>
#include "pksettings.h"
#include "runwindow.h"
#include "packagelist.h"
#include "debug.h"

class Package;
class PmIpkg : public QObject
{
  Q_OBJECT
public:
  PmIpkg( PackageManagerSettings* , QWidget* p=0,  const char * name=0, WFlags f=0 );
  ~PmIpkg();

  void commit( PackageList );
  void update();
  PackageList* getPackageList();
  void showButtons(bool b=true);
  void show( bool buttons=true );

private:
  PackageManagerSettings* settings;
  RunWindow *runwindow;
  QList<Package> to_remove;
  QList<Package> to_install;
  bool runwindowopen;
  QString fileNameToInstall;

  void makeLinks(Package*);
  void linkPackage( QString, QString );
  void processLinkDir( QString, QString );
  int  runIpkg(const QString& args, const QString& dest="" );
  void out( QString );

public slots:
	void doIt();
 	void install();
  void installFileName();
  void remove();
  void installFile(const QString &fileName);
  void linkDestination( const QString, const QByteArray );
};

#endif