1
/* ---------------------------------- manageWizard.h ---------------------------------------------------------------------------
2
header file used by manageWizard.cpp
4
===============================================================================================================================
5
===============================================================================================================================
6
This file is part of "luckyBackup" project
7
Copyright 2008-2010, Loukas Avgeriou
8
luckyBackup is distributed under the terms of the GNU General Public License
9
luckyBackup is free software: you can redistribute it and/or modify
10
it under the terms of the GNU General Public License as published by
11
the Free Software Foundation, either version 3 of the License, or
12
(at your option) any later version.
14
luckyBackup is distributed in the hope that it will be useful,
15
but WITHOUT ANY WARRANTY; without even the implied warranty of
16
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17
GNU General Public License for more details.
19
You should have received a copy of the GNU General Public License
20
along with luckyBackup. If not, see <http://www.gnu.org/licenses/>.
23
project version : Please see "main.cpp" for project version
25
developer : Loukas Avgeriou
26
last modified : 15 Apr 2010
27
===============================================================================================================================
28
===============================================================================================================================
31
#ifndef MANAGEWIZARD_H
32
#define MANAGEWIZARD_H
34
#include "ui_manageWizard.h"
36
//==============================================================================================================
37
//Declaration of manageWizard class (this is the dialog that launches a restore,delete backup wizard)
39
class manageWizard : public QDialog
44
manageWizard (QString, QString, QString, int, QWidget *parent=0);
47
void cancelPressed(); // close the wizard
48
void startAction(); // start the action (restore/delete)
49
void procFinished(); // actions when a process has finished
50
void appendCommandOutput(); // update browser with command running data
51
void abortAction(); //abort the execution of commands
52
void deleteAfterChanged(); // DeleteAfter checkbox state changed
53
void prevError(); //jumb to previous error
54
void nextError(); //jumb to next error
59
QString source; // holds the full path of the original source
60
QString sourceLast; // holds the last child directory of the original source
61
QString dest; // holds the full path of the original destination
62
QString time; // holds the execution time of the selected snapshot in yyyyMMddhhmmss format
63
QString timeReadable; // holds the execution time of the selected snapshot in "yyyy/MM/dd - hh:mm:ss" format
64
int currentSnap; // holds the current snapshot number in the snapshot's list
65
int snapshotsNo; // holds the snapshots number
66
QString wizard_type;// holds the type of the wizard (restore or delete)
67
QStringList commandArguments; // holds the command arguments
69
QString outputString; // holds the standard output of the commands to display at browser
70
QString outputError; // holds the standard error of the commands to display at browser
71
bool procRunning; // this becomes true if a process is running
72
bool procKilled; // this becomes true if a process is aborted
73
int errorCount; // count the errors of the command execution
74
bool DRYrun; // become true if dry-run is checked
75
bool MainRun; // becomes true when main rsync is run. False when the dpecific backed up snapshot files are transfered
76
bool DeleteAfter; // becomes true if "delete files on the source" is checked
77
bool firstScroll; // becomes false if first time next button pressed
78
int count; // simple count variable
80
void calcCommandArgs(); // function to calculate command arguments for RESTORE purposes
81
void runProcess(); //function to run the desired processes
84
void closeEvent(QCloseEvent *event);
90
// end of manageWizard.h ---------------------------------------------------------------------------