1
/* ---------------------------------- scheduleDialog.h ---------------------------------------------------------------------------
2
Header file for scheduleDialog.cpp
4
===============================================================================================================================
5
===============================================================================================================================
6
This file is part of "luckyBackup" project
7
Copyright 2008-2009, 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
26
last modified : 20 April 2009
27
===============================================================================================================================
28
===============================================================================================================================
31
#ifndef SCHEDULEDIALOG_H
32
#define SCHEDULEDIALOG_H
34
//include header file that qmake produces from "*.ui" created with qt designer
35
#include "ui_scheduleDialog.h"
38
//==============================================================================================================
39
//Declaration of rsyncDialog class (this will execute rsync and show progress in a dialog)
40
class scheduleDialog : public QDialog
45
scheduleDialog (QDialog *parent=0);
47
QString schedulename; // schedule file filename
48
int TotalSchedule; //The number of available profiles schedulesin "schedule list"- starts from 1
49
int currentSchedule; //this holds the current row from the "schedule list"- starts from 0
50
void createCron(); //creates a cron file & updates the user's crontab
51
QString CronTab; //QString to hold the user's crontab
52
int count; //simple count variable !!
53
void clearScheduleDetails(); //function: when clear (schedule details) pushbutton pressed
54
QString scheduleText(QString,int,int,int,int,int); //returns the text displayed at the schedule list (eg execute profile default at .... every...)
58
void schedulePressed(); //SLOT when schedule buutton pressed
59
void cancelPressed(); //SLOT when cancel pushbutton pressed
61
void modifyPressed(); //SLOT when modify pushbutton pressed
62
void addPressed(); //SLOT to add an item in the list
63
void removePressed(); //SLOT to remove an item from the list
64
void okaySchedulePressed(); //function to add ot modify a profile schedule
65
void modifyCancelPressed(); //SLOT to initialize widget views
67
void fillDetails(); //SLOT to fill fields of schedule details
68
void appendCrontabOutput(); //SLOT to read user's crontab to a QString
71
Ui::scheduleDialog uiS;
72
int currentProfileIndex; //holds the current profile index inside the combobox
73
bool noSchedules; //becomes true when no schedules are declared
77
void closeEvent(QCloseEvent *event); //when the close button of the dialog pressed
83
// end of scheduleDialog.h ---------------------------------------------------------------------------