kplato
kptstandardworktimedialog.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef KPTSTANDARDWORKTIMEDIALOG_H
00021 #define KPTSTANDARDWORKTIMEDIALOG_H
00022
00023 #include "standardworktimedialogbase.h"
00024 #include "kptcalendar.h"
00025
00026 #include <kdialogbase.h>
00027
00028 #include <qstring.h>
00029
00030 class KMacroCommand;
00031
00032 namespace KPlato
00033 {
00034
00035 class Project;
00036 class Part;
00037
00038 class StandardWorktimeDialogImpl : public StandardWorktimeDialogBase {
00039 Q_OBJECT
00040 public:
00041 StandardWorktimeDialogImpl ( StandardWorktime *std, QWidget *parent);
00042
00043 StandardWorktime *standardWorktime() { return m_std; }
00044 double inYear() const { return m_year; }
00045 double inMonth() const { return m_month; }
00046 double inWeek() const { return m_week; }
00047 double inDay() const { return m_day; }
00048
00049 private slots:
00050 void slotCheckAllFieldsFilled();
00051 void slotEnableButtonOk(bool on);
00052
00053 void slotYearChanged(double);
00054 void slotMonthChanged(double);
00055 void slotWeekChanged(double);
00056 void slotDayChanged(double);
00057
00058 signals:
00059 void obligatedFieldsFilled(bool yes);
00060 void enableButtonOk(bool);
00061
00062 private:
00063 StandardWorktime *m_std;
00064 double m_year;
00065 double m_month;
00066 double m_week;
00067 double m_day;
00068 };
00069
00070 class StandardWorktimeDialog : public KDialogBase {
00071 Q_OBJECT
00072 public:
00073 StandardWorktimeDialog(Project &project, QWidget *parent=0, const char *name=0);
00074
00075 KMacroCommand *buildCommand(Part *part);
00076
00077 protected slots:
00078 void slotOk();
00079
00080 private:
00081 Project &project;
00082 StandardWorktimeDialogImpl *dia;
00083 StandardWorktime *m_original;
00084 };
00085
00086 }
00087
00088 #endif // STANDARDWORKTIMEDIALOG_H
|