1 | /***************************************************************************
|
---|
2 | xmondo.h - description
|
---|
3 | -------------------
|
---|
4 | begin : Thu Apr 24 19:44:32 PDT 2003
|
---|
5 | copyright : (C) 2003 by Joshua Oreman
|
---|
6 | email : oremanj@get-linux.org
|
---|
7 | cvsid : $Id: xmondo.h,v 1.1 2004/06/10 16:13:06 hugo Exp $
|
---|
8 | ***************************************************************************/
|
---|
9 |
|
---|
10 | /***************************************************************************
|
---|
11 | * *
|
---|
12 | * This program is free software; you can redistribute it and/or modify *
|
---|
13 | * it under the terms of the GNU General Public License as published by *
|
---|
14 | * the Free Software Foundation; either version 2 of the License, or *
|
---|
15 | * (at your option) any later version. *
|
---|
16 | * *
|
---|
17 | ***************************************************************************/
|
---|
18 |
|
---|
19 | #ifndef XMONDO_H
|
---|
20 | #define XMONDO_H
|
---|
21 |
|
---|
22 | #undef scroll // newt weirdness
|
---|
23 |
|
---|
24 | #ifdef HAVE_CONFIG_H
|
---|
25 | #include <config.h>
|
---|
26 | #endif
|
---|
27 |
|
---|
28 | #include <kapp.h>
|
---|
29 | #include <kmainwindow.h>
|
---|
30 | #include <kmenubar.h>
|
---|
31 | #include <qwidget.h>
|
---|
32 | #include <qpushbutton.h>
|
---|
33 | #include <qwidgetstack.h>
|
---|
34 | #include <qtabwidget.h>
|
---|
35 | #include "xmondobackup.h"
|
---|
36 |
|
---|
37 | extern "C" {
|
---|
38 | #undef DEBUG
|
---|
39 | #define bool int
|
---|
40 | #include "my-stuff.h"
|
---|
41 | #include "mondostructures.h"
|
---|
42 | #undef bool
|
---|
43 | }
|
---|
44 |
|
---|
45 | class QVButtonGroup;
|
---|
46 | class QLabel;
|
---|
47 | class QLineEdit;
|
---|
48 | class QListView;
|
---|
49 | class QCheckBox;
|
---|
50 |
|
---|
51 | class XMondoBackup;
|
---|
52 | class XMondoRestore;
|
---|
53 |
|
---|
54 | struct s_bkpinfo;
|
---|
55 |
|
---|
56 | /** XMondo is the base class of the project */
|
---|
57 | class XMondo : public KMainWindow
|
---|
58 | {
|
---|
59 | Q_OBJECT
|
---|
60 | public:
|
---|
61 | /** construtor */
|
---|
62 | XMondo(QWidget* parent=0, const char *name=0);
|
---|
63 | /** destructor */
|
---|
64 | virtual ~XMondo();
|
---|
65 |
|
---|
66 | void fillBkpinfo (struct s_bkpinfo *);
|
---|
67 |
|
---|
68 | public slots:
|
---|
69 | void slotVerboseChange (bool v);
|
---|
70 | void slotMode (int x);
|
---|
71 | void slotMediaType (int x);
|
---|
72 | void slotCompareMediaType (int x);
|
---|
73 | void slotRestoreMediaType (int x);
|
---|
74 | void slotStartBackup();
|
---|
75 | void slotStartCompare();
|
---|
76 | void slotAddInclude();
|
---|
77 | void slotAddExclude();
|
---|
78 | void slotDelInclude();
|
---|
79 | void slotDelExclude();
|
---|
80 | void slotTabChange (QWidget *);
|
---|
81 | void slotPrevRestore();
|
---|
82 | void slotNextRestore();
|
---|
83 |
|
---|
84 | private:
|
---|
85 | void initBackupTab (QWidget *&);
|
---|
86 | void initOptionsTab (QWidget *&);
|
---|
87 | void initAdvancedTab (QWidget *&);
|
---|
88 | void initCompareTab (QWidget *&);
|
---|
89 | void initRestoreTab (QWidget *&);
|
---|
90 |
|
---|
91 | QVButtonGroup *buttons;
|
---|
92 | QWidgetStack *stack, *restoreStack;
|
---|
93 | QTabWidget *backup;
|
---|
94 | QWidget *compare, *restore, *tabHardware, *tabOptions, *tabAdvanced, *restoreInfo, *restoreFiles;
|
---|
95 | QPushButton *bStartBackup, *bStartCompare;
|
---|
96 | QPushButton *rPrev, *rNext;
|
---|
97 | QButtonGroup *bgMediaType, *bgCompression, *bgCompareMediaType, *bgCompareCompression, *bgBootLoader, *mainButtons,
|
---|
98 | *bgRestoreMediaType;
|
---|
99 | QLabel *lDOption, *compareLDOption, *nfsRemoteDir, *compareNFSRemoteDir, *restoreLDOption, *restoreNFSRemoteDir;
|
---|
100 | QLineEdit *editDOption, *editMediaSize, *compareEditDOption, *compareEditMediaSize, *restoreEditDOption,
|
---|
101 | *restoreEditMediaSize, *editBootDevice, *editKernel, *editNFSRemoteDir, *compareEditNFSRemoteDir,
|
---|
102 | *restoreEditNFSRemoteDir, *restoreFilter;
|
---|
103 | QListView *listImageDevs, *listInclude, *listExclude, *listExcludeDevs;
|
---|
104 | QCheckBox *checkDifferential, *checkBackupNFS, *checkCompare,
|
---|
105 | *checkMakeBootFloppies, *checkUseLilo;
|
---|
106 | QLineEdit *pendingInclude, *pendingExclude;
|
---|
107 | XMondoBackup *bkup;
|
---|
108 | XMondoRestore *rstr;
|
---|
109 | };
|
---|
110 |
|
---|
111 | #endif
|
---|