Merge commit 'refs/1_0_6_candidate' of https://git.maemo.org/projects/qtmeetings...
[qtmeetings] / src / UserInterface / Views / SettingsView.h
1 #ifndef SETTINGSVIEW_H_
2 #define SETTINGSVIEW_H_
3
4 #include "ViewBase.h"
5
6 class QTabWidget;
7 class QPushButton;
8 class QLineEdit;
9 class QTimeEdit;
10 class QRadioButton;
11 class QCheckBox;
12 class QSize;
13 class QTime;
14
15 //! User interface class. Shows the settings view and handles configuration changes.
16 class SettingsView : public ViewBase
17 {
18         Q_OBJECT
19
20 public:
21         //! Constructor.
22         /*!
23          * Constructor to initialize and prepare the settings view. This calls internally
24          * the helper methods to initialize individual setting tabs.
25          * \param Parent component.
26          */
27         SettingsView( QWidget *aParent = 0 );
28         //! Destructor.
29         virtual ~SettingsView();
30         
31 signals:
32         void okClicked();
33         
34         void cancelClicked();
35         
36 public slots:
37         void viewResized(const QSize &newSize, const QSize &oldSize);
38
39 private slots:
40         //! Slot to handle the Ok button pressing.
41         void handleOkClicked();
42         //! Slot to handle the Cancel button pressing.
43         void handleCancelClicked();
44         //! Slot to handle the day end time minimum value
45         void dayStartTimeChanged( const QTime &aTime );
46
47 private:
48         //! Initialize "Settings" tab.
49         QWidget *initSettingsTab();
50         //! Initialize "Week View" tab.
51         QWidget *initWeekViewTab();
52         //! Intialize "Resources" tab.
53         QWidget *initResourcesTab();
54         //! Initialize "KIOSK Mode" tab.
55         QWidget *initKioskModeTab();
56         //! Set values to fields
57         void setValues();
58
59         //! The tabbed settings view component.
60         QTabWidget *iTabWidget;
61         //! OK button to dismiss the settings view with saving the settings.
62         QPushButton *iOkButton;
63         //! Cancel button to dismiss the settings view without saving the settings
64         QPushButton *iCancelButton;
65         //! Settings tab.
66         QWidget *iSettingsTab;
67         //! Week View tab.
68         QWidget *iWeekViewTab;
69         //! Resources tab.
70         QWidget *iResourcesTab;
71         //! KIOSK Mode tab.
72         QWidget *iKioskModeTab;
73
74         //! User name to the remote server.
75         QLineEdit *iUserName;
76         //! Password to the remote server.
77         QLineEdit *iPassword;
78         //! Remote server address.
79         QLineEdit *iServerAddress;
80         //! Refresh interval in seconds.
81         QLineEdit *iRefreshInterval;
82         //! When the day starts in the calendar view.
83         QTimeEdit *iDayStartTime;
84         //! When the day ends in the calendar view.
85         QTimeEdit *iDayEndTime;
86         //! Selection for showing five days in the calendar.
87         QRadioButton *iFiveDays;
88         //! Selection for showing seven days in the calendar.
89         QRadioButton *iSevenDays;
90         //! Power saving enabling.
91         QCheckBox *iPowerSaveEnabled;
92         //! Start time for activating power save.
93         QTimeEdit *iPowerSaveStartTime;
94         //! End time for deactivating power save.
95         QTimeEdit *iPowerSaveEndTime;
96
97         //! Show confidential meeting details.
98         QCheckBox *iShowConfidentialMeetingDetails;
99 };
100
101 #endif /*SETTINGSVIEW_H_*/