-rw-r--r-- | core/pim/datebook/datebookdayheader.cpp | 207 | ||||
-rw-r--r-- | core/pim/datebook/datebookdayheader.h | 56 | ||||
-rw-r--r-- | core/pim/datebook/datebookweeklstheader.cpp | 206 | ||||
-rw-r--r-- | core/pim/datebook/dateentry.cpp | 255 |
4 files changed, 0 insertions, 724 deletions
diff --git a/core/pim/datebook/datebookdayheader.cpp b/core/pim/datebook/datebookdayheader.cpp deleted file mode 100644 index 82a143f..0000000 --- a/core/pim/datebook/datebookdayheader.cpp +++ b/dev/null | |||
@@ -1,207 +0,0 @@ | |||
1 | /**************************************************************************** | ||
2 | ** Form implementation generated from reading ui file 'datebookdayheader.ui' | ||
3 | ** | ||
4 | ** Created: Mon Mar 24 10:42:07 2003 | ||
5 | ** by: The User Interface Compiler (uic) | ||
6 | ** | ||
7 | ** WARNING! All changes made in this file will be lost! | ||
8 | ****************************************************************************/ | ||
9 | #include "datebookdayheader.h" | ||
10 | |||
11 | #include <qbuttongroup.h> | ||
12 | #include <qpushbutton.h> | ||
13 | #include <qtoolbutton.h> | ||
14 | #include <qlayout.h> | ||
15 | #include <qvariant.h> | ||
16 | #include <qtooltip.h> | ||
17 | #include <qwhatsthis.h> | ||
18 | #include <qimage.h> | ||
19 | #include <qpixmap.h> | ||
20 | |||
21 | |||
22 | /* | ||
23 | * Constructs a DateBookDayHeaderBase which is a child of 'parent', with the | ||
24 | * name 'name' and widget flags set to 'f' | ||
25 | */ | ||
26 | DateBookDayHeaderBase::DateBookDayHeaderBase( QWidget* parent, const char* name, WFlags fl ) | ||
27 | : QWidget( parent, name, fl ) | ||
28 | { | ||
29 | if ( !name ) | ||
30 | setName( "DateBookDayHeaderBase" ); | ||
31 | resize( 249, 26 ); | ||
32 | DateBookDayHeaderBaseLayout = new QHBoxLayout( this ); | ||
33 | DateBookDayHeaderBaseLayout->setSpacing( 0 ); | ||
34 | DateBookDayHeaderBaseLayout->setMargin( 0 ); | ||
35 | |||
36 | backweek = new QToolButton( this, "backweek" ); | ||
37 | backweek->setText( tr( "" ) ); | ||
38 | backweek->setToggleButton( FALSE ); | ||
39 | backweek->setAutoRepeat( TRUE ); | ||
40 | backweek->setAutoRaise( TRUE ); | ||
41 | backweek->setToggleButton( FALSE ); | ||
42 | QToolTip::add( backweek, tr( "" ) ); | ||
43 | DateBookDayHeaderBaseLayout->addWidget( backweek ); | ||
44 | |||
45 | back = new QToolButton( this, "back" ); | ||
46 | back->setText( tr( "" ) ); | ||
47 | back->setToggleButton( FALSE ); | ||
48 | back->setAutoRepeat( TRUE ); | ||
49 | back->setAutoRaise( TRUE ); | ||
50 | back->setToggleButton( FALSE ); | ||
51 | QToolTip::add( back, tr( "" ) ); | ||
52 | DateBookDayHeaderBaseLayout->addWidget( back ); | ||
53 | |||
54 | date = new QToolButton( this, "date" ); | ||
55 | date->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)1, date->sizePolicy().hasHeightForWidth() ) ); | ||
56 | QFont date_font( date->font() ); | ||
57 | date_font.setBold( TRUE ); | ||
58 | date->setFont( date_font ); | ||
59 | date->setText( tr( "" ) ); | ||
60 | date->setAutoRepeat( FALSE ); | ||
61 | date->setAutoRaise( FALSE ); | ||
62 | DateBookDayHeaderBaseLayout->addWidget( date ); | ||
63 | |||
64 | grpDays = new QButtonGroup( this, "grpDays" ); | ||
65 | grpDays->setFrameShape( QButtonGroup::NoFrame ); | ||
66 | grpDays->setFrameShadow( QButtonGroup::Plain ); | ||
67 | grpDays->setTitle( tr( "" ) ); | ||
68 | grpDays->setExclusive( TRUE ); | ||
69 | grpDays->setColumnLayout(0, Qt::Vertical ); | ||
70 | grpDays->layout()->setSpacing( 0 ); | ||
71 | grpDays->layout()->setMargin( 0 ); | ||
72 | grpDaysLayout = new QHBoxLayout( grpDays->layout() ); | ||
73 | grpDaysLayout->setAlignment( Qt::AlignTop ); | ||
74 | grpDaysLayout->setSpacing( 1 ); | ||
75 | grpDaysLayout->setMargin( 0 ); | ||
76 | |||
77 | cmdDay1 = new QToolButton( grpDays, "cmdDay1" ); | ||
78 | cmdDay1->setText( tr( "M" ) ); | ||
79 | cmdDay1->setToggleButton( TRUE ); | ||
80 | cmdDay1->setAutoRaise( TRUE ); | ||
81 | cmdDay1->setToggleButton( TRUE ); | ||
82 | QToolTip::add( cmdDay1, tr( "" ) ); | ||
83 | grpDaysLayout->addWidget( cmdDay1 ); | ||
84 | |||
85 | cmdDay2 = new QToolButton( grpDays, "cmdDay2" ); | ||
86 | cmdDay2->setText( tr( "T" ) ); | ||
87 | cmdDay2->setToggleButton( TRUE ); | ||
88 | cmdDay2->setAutoRaise( TRUE ); | ||
89 | cmdDay2->setToggleButton( TRUE ); | ||
90 | QToolTip::add( cmdDay2, tr( "" ) ); | ||
91 | grpDaysLayout->addWidget( cmdDay2 ); | ||
92 | |||
93 | cmdDay3 = new QToolButton( grpDays, "cmdDay3" ); | ||
94 | cmdDay3->setText( tr( "W" ) ); | ||
95 | cmdDay3->setToggleButton( TRUE ); | ||
96 | cmdDay3->setAutoRaise( TRUE ); | ||
97 | cmdDay3->setToggleButton( TRUE ); | ||
98 | QToolTip::add( cmdDay3, tr( "" ) ); | ||
99 | grpDaysLayout->addWidget( cmdDay3 ); | ||
100 | |||
101 | cmdDay4 = new QToolButton( grpDays, "cmdDay4" ); | ||
102 | cmdDay4->setText( tr( "T" ) ); | ||
103 | cmdDay4->setToggleButton( TRUE ); | ||
104 | cmdDay4->setAutoRepeat( FALSE ); | ||
105 | cmdDay4->setAutoRaise( TRUE ); | ||
106 | cmdDay4->setToggleButton( TRUE ); | ||
107 | QToolTip::add( cmdDay4, tr( "" ) ); | ||
108 | grpDaysLayout->addWidget( cmdDay4 ); | ||
109 | |||
110 | cmdDay5 = new QToolButton( grpDays, "cmdDay5" ); | ||
111 | cmdDay5->setText( tr( "F" ) ); | ||
112 | cmdDay5->setToggleButton( TRUE ); | ||
113 | cmdDay5->setAutoRaise( TRUE ); | ||
114 | cmdDay5->setToggleButton( TRUE ); | ||
115 | QToolTip::add( cmdDay5, tr( "" ) ); | ||
116 | grpDaysLayout->addWidget( cmdDay5 ); | ||
117 | |||
118 | cmdDay6 = new QToolButton( grpDays, "cmdDay6" ); | ||
119 | cmdDay6->setText( tr( "S" ) ); | ||
120 | cmdDay6->setToggleButton( TRUE ); | ||
121 | cmdDay6->setAutoRaise( TRUE ); | ||
122 | cmdDay6->setToggleButton( TRUE ); | ||
123 | QToolTip::add( cmdDay6, tr( "" ) ); | ||
124 | grpDaysLayout->addWidget( cmdDay6 ); | ||
125 | |||
126 | cmdDay7 = new QToolButton( grpDays, "cmdDay7" ); | ||
127 | cmdDay7->setText( tr( "S" ) ); | ||
128 | cmdDay7->setToggleButton( TRUE ); | ||
129 | cmdDay7->setAutoRaise( TRUE ); | ||
130 | cmdDay7->setToggleButton( TRUE ); | ||
131 | QToolTip::add( cmdDay7, tr( "" ) ); | ||
132 | grpDaysLayout->addWidget( cmdDay7 ); | ||
133 | DateBookDayHeaderBaseLayout->addWidget( grpDays ); | ||
134 | |||
135 | forward = new QToolButton( this, "forward" ); | ||
136 | forward->setText( tr( "" ) ); | ||
137 | forward->setAutoRepeat( TRUE ); | ||
138 | forward->setAutoRaise( TRUE ); | ||
139 | DateBookDayHeaderBaseLayout->addWidget( forward ); | ||
140 | |||
141 | forwardweek = new QToolButton( this, "forwardweek" ); | ||
142 | forwardweek->setText( tr( "" ) ); | ||
143 | forwardweek->setAutoRepeat( TRUE ); | ||
144 | forwardweek->setAutoRaise( TRUE ); | ||
145 | DateBookDayHeaderBaseLayout->addWidget( forwardweek ); | ||
146 | |||
147 | // signals and slots connections | ||
148 | connect( forwardweek, SIGNAL( clicked() ), this, SLOT( goForwardWeek() ) ); | ||
149 | connect( forward, SIGNAL( clicked() ), this, SLOT( goForward() ) ); | ||
150 | connect( back, SIGNAL( clicked() ), this, SLOT( goBack() ) ); | ||
151 | connect( backweek, SIGNAL( clicked() ), this, SLOT( goBackWeek() ) ); | ||
152 | connect( grpDays, SIGNAL( clicked(int) ), this, SLOT( setDay( int ) ) ); | ||
153 | } | ||
154 | |||
155 | /* | ||
156 | * Destroys the object and frees any allocated resources | ||
157 | */ | ||
158 | DateBookDayHeaderBase::~DateBookDayHeaderBase() | ||
159 | { | ||
160 | // no need to delete child widgets, Qt does it all for us | ||
161 | } | ||
162 | |||
163 | /* | ||
164 | * Main event handler. Reimplemented to handle application | ||
165 | * font changes | ||
166 | */ | ||
167 | bool DateBookDayHeaderBase::event( QEvent* ev ) | ||
168 | { | ||
169 | bool ret = QWidget::event( ev ); | ||
170 | if ( ev->type() == QEvent::ApplicationFontChange ) { | ||
171 | QFont date_font( date->font() ); | ||
172 | date_font.setBold( TRUE ); | ||
173 | date->setFont( date_font ); | ||
174 | } | ||
175 | return ret; | ||
176 | } | ||
177 | |||
178 | void DateBookDayHeaderBase::goBack() | ||
179 | { | ||
180 | qWarning( "DateBookDayHeaderBase::goBack(): Not implemented yet!" ); | ||
181 | } | ||
182 | |||
183 | void DateBookDayHeaderBase::goBackWeek() | ||
184 | { | ||
185 | qWarning( "DateBookDayHeaderBase::goBackWeek(): Not implemented yet!" ); | ||
186 | } | ||
187 | |||
188 | void DateBookDayHeaderBase::goForward() | ||
189 | { | ||
190 | qWarning( "DateBookDayHeaderBase::goForward(): Not implemented yet!" ); | ||
191 | } | ||
192 | |||
193 | void DateBookDayHeaderBase::goForwardWeek() | ||
194 | { | ||
195 | qWarning( "DateBookDayHeaderBase::goForwardWeek(): Not implemented yet!" ); | ||
196 | } | ||
197 | |||
198 | void DateBookDayHeaderBase::setDate( int, int, int ) | ||
199 | { | ||
200 | qWarning( "DateBookDayHeaderBase::setDate( int, int, int ): Not implemented yet!" ); | ||
201 | } | ||
202 | |||
203 | void DateBookDayHeaderBase::setDay( int ) | ||
204 | { | ||
205 | qWarning( "DateBookDayHeaderBase::setDay( int ): Not implemented yet!" ); | ||
206 | } | ||
207 | |||
diff --git a/core/pim/datebook/datebookdayheader.h b/core/pim/datebook/datebookdayheader.h deleted file mode 100644 index 12f6fcf..0000000 --- a/core/pim/datebook/datebookdayheader.h +++ b/dev/null | |||
@@ -1,56 +0,0 @@ | |||
1 | /**************************************************************************** | ||
2 | ** Form interface generated from reading ui file 'datebookdayheader.ui' | ||
3 | ** | ||
4 | ** Created: Mon Mar 10 20:49:12 2003 | ||
5 | ** by: The User Interface Compiler (uic) | ||
6 | ** | ||
7 | ** WARNING! All changes made in this file will be lost! | ||
8 | ****************************************************************************/ | ||
9 | #ifndef DATEBOOKDAYHEADERBASE_H | ||
10 | #define DATEBOOKDAYHEADERBASE_H | ||
11 | |||
12 | #include <qvariant.h> | ||
13 | #include <qwidget.h> | ||
14 | class QVBoxLayout; | ||
15 | class QHBoxLayout; | ||
16 | class QGridLayout; | ||
17 | class QButtonGroup; | ||
18 | class QToolButton; | ||
19 | |||
20 | class DateBookDayHeaderBase : public QWidget | ||
21 | { | ||
22 | Q_OBJECT | ||
23 | |||
24 | public: | ||
25 | DateBookDayHeaderBase( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); | ||
26 | ~DateBookDayHeaderBase(); | ||
27 | |||
28 | QToolButton* backweek; | ||
29 | QToolButton* back; | ||
30 | QToolButton* date; | ||
31 | QButtonGroup* grpDays; | ||
32 | QToolButton* cmdDay1; | ||
33 | QToolButton* cmdDay2; | ||
34 | QToolButton* cmdDay3; | ||
35 | QToolButton* cmdDay4; | ||
36 | QToolButton* cmdDay5; | ||
37 | QToolButton* cmdDay6; | ||
38 | QToolButton* cmdDay7; | ||
39 | QToolButton* forward; | ||
40 | QToolButton* forwardweek; | ||
41 | |||
42 | public slots: | ||
43 | virtual void goBackWeek(); | ||
44 | virtual void goBack(); | ||
45 | virtual void goForward(); | ||
46 | virtual void goForwardWeek(); | ||
47 | virtual void setDate( int, int, int ); | ||
48 | virtual void setDay( int ); | ||
49 | |||
50 | protected: | ||
51 | QHBoxLayout* DateBookDayHeaderBaseLayout; | ||
52 | QHBoxLayout* grpDaysLayout; | ||
53 | bool event( QEvent* ); | ||
54 | }; | ||
55 | |||
56 | #endif // DATEBOOKDAYHEADERBASE_H | ||
diff --git a/core/pim/datebook/datebookweeklstheader.cpp b/core/pim/datebook/datebookweeklstheader.cpp deleted file mode 100644 index 582dc96..0000000 --- a/core/pim/datebook/datebookweeklstheader.cpp +++ b/dev/null | |||
@@ -1,206 +0,0 @@ | |||
1 | /**************************************************************************** | ||
2 | ** Form implementation generated from reading ui file 'datebookweeklstheader.ui' | ||
3 | ** | ||
4 | ** Created: Mon Mar 10 20:50:34 2003 | ||
5 | ** by: The User Interface Compiler (uic) | ||
6 | ** | ||
7 | ** WARNING! All changes made in this file will be lost! | ||
8 | ****************************************************************************/ | ||
9 | #include "datebookweeklstheader.h" | ||
10 | |||
11 | #include <qlabel.h> | ||
12 | #include <qpushbutton.h> | ||
13 | #include <qtoolbutton.h> | ||
14 | #include <qlayout.h> | ||
15 | #include <qvariant.h> | ||
16 | #include <qtooltip.h> | ||
17 | #include <qwhatsthis.h> | ||
18 | #include <qimage.h> | ||
19 | #include <qpixmap.h> | ||
20 | |||
21 | #include <qpe/resource.h> | ||
22 | |||
23 | static const char* const image0_data[] = { | ||
24 | "14 14 19 1", | ||
25 | ". c None", | ||
26 | "# c #000000", | ||
27 | "c c #202420", | ||
28 | "a c #202429", | ||
29 | "f c #525052", | ||
30 | "o c #52595a", | ||
31 | "m c #5a5d5a", | ||
32 | "l c #cdcacd", | ||
33 | "k c #cdcecd", | ||
34 | "q c #d5d6d5", | ||
35 | "i c #ded6de", | ||
36 | "j c #e6dee6", | ||
37 | "p c #eeeaee", | ||
38 | "h c #f6eef6", | ||
39 | "n c #f6f2f6", | ||
40 | "e c #f6f6f6", | ||
41 | "g c #fff6ff", | ||
42 | "d c #fffaff", | ||
43 | "b c #ffffff", | ||
44 | "..............", | ||
45 | ".......##.....", | ||
46 | "......ab#.....", | ||
47 | ".....cbb##....", | ||
48 | "....abbd####..", | ||
49 | "...cbbbbbbe#..", | ||
50 | "..fbbbbgdhi##.", | ||
51 | "...abbejkll##.", | ||
52 | "...maenk#####.", | ||
53 | "....oapk####..", | ||
54 | ".....oaq##....", | ||
55 | "......o###....", | ||
56 | "..............", | ||
57 | ".............."}; | ||
58 | |||
59 | static const char* const image1_data[] = { | ||
60 | "14 14 22 1", | ||
61 | ". c None", | ||
62 | "# c #000000", | ||
63 | "c c #202020", | ||
64 | "g c #202420", | ||
65 | "q c #414041", | ||
66 | "k c #4a484a", | ||
67 | "e c #5a5d62", | ||
68 | "d c #5a6162", | ||
69 | "a c #62696a", | ||
70 | "p c #cdcacd", | ||
71 | "s c #d5ced5", | ||
72 | "o c #d5d2d5", | ||
73 | "j c #ded6de", | ||
74 | "r c #dedade", | ||
75 | "l c #e6e2e6", | ||
76 | "m c #eeeaee", | ||
77 | "h c #f6eef6", | ||
78 | "i c #f6f2f6", | ||
79 | "t c #f6f6f6", | ||
80 | "f c #fff6ff", | ||
81 | "n c #fffaff", | ||
82 | "b c #ffffff", | ||
83 | "..............", | ||
84 | ".....##a......", | ||
85 | ".....#bcd.....", | ||
86 | ".....#bbce....", | ||
87 | "..####bbfge...", | ||
88 | "..#bbbbbfhce..", | ||
89 | "..#bbbbbijjk..", | ||
90 | "..#flmniopcq..", | ||
91 | "..####nrsgq#..", | ||
92 | "....##tpcq#...", | ||
93 | ".....#hgq#....", | ||
94 | ".....##q#.....", | ||
95 | "..............", | ||
96 | ".............."}; | ||
97 | |||
98 | |||
99 | /* | ||
100 | * Constructs a DateBookWeekLstHeaderBase which is a child of 'parent', with the | ||
101 | * name 'name' and widget flags set to 'f' | ||
102 | */ | ||
103 | DateBookWeekLstHeaderBase::DateBookWeekLstHeaderBase( QWidget* parent, const char* name, WFlags fl ) | ||
104 | : QWidget( parent, name, fl ) | ||
105 | { | ||
106 | QPixmap image0( ( const char** ) image0_data ); | ||
107 | QPixmap image1( ( const char** ) image1_data ); | ||
108 | if ( !name ) | ||
109 | setName( "DateBookWeekLstHeaderBase" ); | ||
110 | resize( 447, 45 ); | ||
111 | setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, sizePolicy().hasHeightForWidth() ) ); | ||
112 | DateBookWeekLstHeaderBaseLayout = new QHBoxLayout( this ); | ||
113 | DateBookWeekLstHeaderBaseLayout->setSpacing( 6 ); | ||
114 | DateBookWeekLstHeaderBaseLayout->setMargin( 11 ); | ||
115 | |||
116 | back = new QToolButton( this, "back" ); | ||
117 | back->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, back->sizePolicy().hasHeightForWidth() ) ); | ||
118 | back->setText( tr( "" ) ); | ||
119 | back->setPixmap( image0 ); | ||
120 | back->setPixmap( Resource::loadPixmap( "back" ) ); | ||
121 | back->setToggleButton( FALSE ); | ||
122 | back->setAutoRepeat( TRUE ); | ||
123 | back->setAutoRaise( TRUE ); | ||
124 | back->setToggleButton( FALSE ); | ||
125 | QToolTip::add( back, tr( "" ) ); | ||
126 | DateBookWeekLstHeaderBaseLayout->addWidget( back ); | ||
127 | QSpacerItem* spacer = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); | ||
128 | DateBookWeekLstHeaderBaseLayout->addItem( spacer ); | ||
129 | |||
130 | labelWeek = new QToolButton( this, "labelWeek" ); | ||
131 | labelWeek->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, labelWeek->sizePolicy().hasHeightForWidth() ) ); | ||
132 | QFont labelWeek_font( labelWeek->font() ); | ||
133 | labelWeek_font.setBold( TRUE ); | ||
134 | labelWeek->setFont( labelWeek_font ); | ||
135 | labelWeek->setText( tr( "W: 00,00" ) ); | ||
136 | labelWeek->setToggleButton( FALSE ); | ||
137 | labelWeek->setAutoRaise( FALSE ); | ||
138 | labelWeek->setToggleButton( FALSE ); | ||
139 | QToolTip::add( labelWeek, tr( "" ) ); | ||
140 | DateBookWeekLstHeaderBaseLayout->addWidget( labelWeek ); | ||
141 | QSpacerItem* spacer_2 = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); | ||
142 | DateBookWeekLstHeaderBaseLayout->addItem( spacer_2 ); | ||
143 | |||
144 | dbl = new QToolButton( this, "dbl" ); | ||
145 | dbl->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)3, (QSizePolicy::SizeType)0, dbl->sizePolicy().hasHeightForWidth() ) ); | ||
146 | QFont dbl_font( dbl->font() ); | ||
147 | dbl_font.setBold( TRUE ); | ||
148 | dbl->setFont( dbl_font ); | ||
149 | dbl->setText( tr( "2" ) ); | ||
150 | dbl->setToggleButton( TRUE ); | ||
151 | dbl->setAutoRaise( FALSE ); | ||
152 | dbl->setToggleButton( TRUE ); | ||
153 | QToolTip::add( dbl, tr( "" ) ); | ||
154 | DateBookWeekLstHeaderBaseLayout->addWidget( dbl ); | ||
155 | QSpacerItem* spacer_3 = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); | ||
156 | DateBookWeekLstHeaderBaseLayout->addItem( spacer_3 ); | ||
157 | |||
158 | labelDate = new QLabel( this, "labelDate" ); | ||
159 | labelDate->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)3, (QSizePolicy::SizeType)7, labelDate->sizePolicy().hasHeightForWidth() ) ); | ||
160 | QFont labelDate_font( labelDate->font() ); | ||
161 | labelDate_font.setBold( TRUE ); | ||
162 | labelDate->setFont( labelDate_font ); | ||
163 | labelDate->setText( tr( "00 Jan-00 Jan" ) ); | ||
164 | DateBookWeekLstHeaderBaseLayout->addWidget( labelDate ); | ||
165 | QSpacerItem* spacer_4 = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); | ||
166 | DateBookWeekLstHeaderBaseLayout->addItem( spacer_4 ); | ||
167 | |||
168 | forward = new QToolButton( this, "forward" ); | ||
169 | forward->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)1, (QSizePolicy::SizeType)0, forward->sizePolicy().hasHeightForWidth() ) ); | ||
170 | forward->setText( tr( "" ) ); | ||
171 | forward->setPixmap( image1 ); | ||
172 | forward->setPixmap( Resource::loadPixmap( "forward" ) ); | ||
173 | forward->setAutoRepeat( TRUE ); | ||
174 | forward->setAutoRaise( TRUE ); | ||
175 | DateBookWeekLstHeaderBaseLayout->addWidget( forward ); | ||
176 | } | ||
177 | |||
178 | /* | ||
179 | * Destroys the object and frees any allocated resources | ||
180 | */ | ||
181 | DateBookWeekLstHeaderBase::~DateBookWeekLstHeaderBase() | ||
182 | { | ||
183 | // no need to delete child widgets, Qt does it all for us | ||
184 | } | ||
185 | |||
186 | /* | ||
187 | * Main event handler. Reimplemented to handle application | ||
188 | * font changes | ||
189 | */ | ||
190 | bool DateBookWeekLstHeaderBase::event( QEvent* ev ) | ||
191 | { | ||
192 | bool ret = QWidget::event( ev ); | ||
193 | if ( ev->type() == QEvent::ApplicationFontChange ) { | ||
194 | QFont labelWeek_font( labelWeek->font() ); | ||
195 | labelWeek_font.setBold( TRUE ); | ||
196 | labelWeek->setFont( labelWeek_font ); | ||
197 | QFont dbl_font( dbl->font() ); | ||
198 | dbl_font.setBold( TRUE ); | ||
199 | dbl->setFont( dbl_font ); | ||
200 | QFont labelDate_font( labelDate->font() ); | ||
201 | labelDate_font.setBold( TRUE ); | ||
202 | labelDate->setFont( labelDate_font ); | ||
203 | } | ||
204 | return ret; | ||
205 | } | ||
206 | |||
diff --git a/core/pim/datebook/dateentry.cpp b/core/pim/datebook/dateentry.cpp deleted file mode 100644 index 95ddee8..0000000 --- a/core/pim/datebook/dateentry.cpp +++ b/dev/null | |||
@@ -1,255 +0,0 @@ | |||
1 | /**************************************************************************** | ||
2 | ** Form implementation generated from reading ui file 'dateentry.ui' | ||
3 | ** | ||
4 | ** Created: Mon Mar 10 20:50:24 2003 | ||
5 | ** by: The User Interface Compiler (uic) | ||
6 | ** | ||
7 | ** WARNING! All changes made in this file will be lost! | ||
8 | ****************************************************************************/ | ||
9 | #include "dateentry.h" | ||
10 | |||
11 | #include <qcheckbox.h> | ||
12 | #include <qcombobox.h> | ||
13 | #include <qlabel.h> | ||
14 | #include <qlineedit.h> | ||
15 | #include <qpe/categoryselect.h> | ||
16 | #include <qpe/tzselect.h> | ||
17 | #include <qpushbutton.h> | ||
18 | #include <qspinbox.h> | ||
19 | #include <qtoolbutton.h> | ||
20 | #include "timepicker.h" | ||
21 | #include <qlayout.h> | ||
22 | #include <qvariant.h> | ||
23 | #include <qtooltip.h> | ||
24 | #include <qwhatsthis.h> | ||
25 | |||
26 | /* | ||
27 | * Constructs a DateEntryBase which is a child of 'parent', with the | ||
28 | * name 'name' and widget flags set to 'f' | ||
29 | */ | ||
30 | DateEntryBase::DateEntryBase( QWidget* parent, const char* name, WFlags fl ) | ||
31 | : QWidget( parent, name, fl ) | ||
32 | { | ||
33 | if ( !name ) | ||
34 | setName( "DateEntryBase" ); | ||
35 | resize( 242, 339 ); | ||
36 | setCaption( tr( "New Event" ) ); | ||
37 | DateEntryBaseLayout = new QGridLayout( this ); | ||
38 | DateEntryBaseLayout->setSpacing( 0 ); | ||
39 | DateEntryBaseLayout->setMargin( 2 ); | ||
40 | |||
41 | TextLabel2 = new QLabel( this, "TextLabel2" ); | ||
42 | TextLabel2->setFrameShape( QLabel::MShape ); | ||
43 | TextLabel2->setFrameShadow( QLabel::MShadow ); | ||
44 | TextLabel2->setText( tr( "Location" ) ); | ||
45 | |||
46 | DateEntryBaseLayout->addWidget( TextLabel2, 1, 0 ); | ||
47 | |||
48 | TextLabel2_2 = new QLabel( this, "TextLabel2_2" ); | ||
49 | TextLabel2_2->setText( tr( "Category" ) ); | ||
50 | |||
51 | DateEntryBaseLayout->addWidget( TextLabel2_2, 2, 0 ); | ||
52 | |||
53 | comboDescription = new QComboBox( FALSE, this, "comboDescription" ); | ||
54 | comboDescription->insertItem( tr( "" ) ); | ||
55 | comboDescription->insertItem( tr( "Meeting" ) ); | ||
56 | comboDescription->insertItem( tr( "Lunch" ) ); | ||
57 | comboDescription->insertItem( tr( "Dinner" ) ); | ||
58 | comboDescription->insertItem( tr( "Travel" ) ); | ||
59 | comboDescription->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, comboDescription->sizePolicy().hasHeightForWidth() ) ); | ||
60 | comboDescription->setEditable( TRUE ); | ||
61 | comboDescription->setCurrentItem( 0 ); | ||
62 | comboDescription->setDuplicatesEnabled( FALSE ); | ||
63 | |||
64 | DateEntryBaseLayout->addMultiCellWidget( comboDescription, 0, 0, 1, 3 ); | ||
65 | |||
66 | TextLabel1 = new QLabel( this, "TextLabel1" ); | ||
67 | TextLabel1->setText( tr( "Description " ) ); | ||
68 | |||
69 | DateEntryBaseLayout->addWidget( TextLabel1, 0, 0 ); | ||
70 | |||
71 | comboLocation = new QComboBox( FALSE, this, "comboLocation" ); | ||
72 | comboLocation->insertItem( tr( "" ) ); | ||
73 | comboLocation->insertItem( tr( "Office" ) ); | ||
74 | comboLocation->insertItem( tr( "Home" ) ); | ||
75 | comboLocation->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, comboLocation->sizePolicy().hasHeightForWidth() ) ); | ||
76 | comboLocation->setEditable( TRUE ); | ||
77 | comboLocation->setCurrentItem( 0 ); | ||
78 | comboLocation->setDuplicatesEnabled( FALSE ); | ||
79 | |||
80 | DateEntryBaseLayout->addMultiCellWidget( comboLocation, 1, 1, 1, 3 ); | ||
81 | |||
82 | comboCategory = new CategorySelect( this, "comboCategory" ); | ||
83 | |||
84 | DateEntryBaseLayout->addMultiCellWidget( comboCategory, 2, 2, 1, 3 ); | ||
85 | |||
86 | TextLabel3 = new QLabel( this, "TextLabel3" ); | ||
87 | TextLabel3->setText( tr( "Start - End " ) ); | ||
88 | |||
89 | DateEntryBaseLayout->addMultiCellWidget( TextLabel3, 3, 4, 0, 0 ); | ||
90 | |||
91 | buttonStart = new QPushButton( this, "buttonStart" ); | ||
92 | buttonStart->setText( tr( "Jan 02 00" ) ); | ||
93 | buttonStart->setMinimumSize( QSize( 70, 0 ) ); | ||
94 | buttonStart->setMaximumSize( QSize( 70, 32767 ) ); | ||
95 | |||
96 | DateEntryBaseLayout->addWidget( buttonStart, 3, 1 ); | ||
97 | |||
98 | comboStart = new QLineEdit( this, "comboStart" ); | ||
99 | comboStart->setMinimumSize( QSize( 70, 0 ) ); | ||
100 | comboStart->setMaximumSize( QSize( 70, 32767 ) ); | ||
101 | comboStart->setAlignment( int( QLineEdit::AlignHCenter ) ); | ||
102 | |||
103 | DateEntryBaseLayout->addWidget( comboStart, 4, 1 ); | ||
104 | QSpacerItem* spacer = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); | ||
105 | DateEntryBaseLayout->addMultiCell( spacer, 3, 4, 2, 2 ); | ||
106 | |||
107 | timePickerStart = new TimePicker( this, "timePickerStart" ); | ||
108 | |||
109 | DateEntryBaseLayout->addMultiCellWidget( timePickerStart, 5, 5, 1, 3 ); | ||
110 | |||
111 | buttonEnd = new QPushButton( this, "buttonEnd" ); | ||
112 | buttonEnd->setText( tr( "Jan 02 00" ) ); | ||
113 | buttonEnd->setMinimumSize( QSize( 70, 0 ) ); | ||
114 | buttonEnd->setMaximumSize( QSize( 70, 32767 ) ); | ||
115 | |||
116 | DateEntryBaseLayout->addWidget( buttonEnd, 3, 3 ); | ||
117 | |||
118 | comboEnd = new QLineEdit( this, "comboEnd" ); | ||
119 | comboEnd->setMinimumSize( QSize( 70, 0 ) ); | ||
120 | comboEnd->setMaximumSize( QSize( 70, 32767 ) ); | ||
121 | comboEnd->setAlignment( int( QLineEdit::AlignHCenter ) ); | ||
122 | |||
123 | DateEntryBaseLayout->addWidget( comboEnd, 4, 3 ); | ||
124 | |||
125 | TimePickerLabel = new QLabel( this, "TimePickerLabel" ); | ||
126 | TimePickerLabel->setText( tr( "Start time" ) ); | ||
127 | |||
128 | DateEntryBaseLayout->addWidget( TimePickerLabel, 5, 0 ); | ||
129 | |||
130 | checkAllDay = new QCheckBox( this, "checkAllDay" ); | ||
131 | checkAllDay->setText( tr( "All day" ) ); | ||
132 | |||
133 | DateEntryBaseLayout->addWidget( checkAllDay, 6, 0 ); | ||
134 | |||
135 | TextLabel3_2_2 = new QLabel( this, "TextLabel3_2_2" ); | ||
136 | TextLabel3_2_2->setText( tr( "Time zone" ) ); | ||
137 | |||
138 | DateEntryBaseLayout->addWidget( TextLabel3_2_2, 7, 0 ); | ||
139 | |||
140 | timezone = new TimeZoneSelector( this, "timezone" ); | ||
141 | |||
142 | DateEntryBaseLayout->addMultiCellWidget( timezone, 7, 7, 1, 3 ); | ||
143 | |||
144 | checkAlarm = new QCheckBox( this, "checkAlarm" ); | ||
145 | checkAlarm->setEnabled( TRUE ); | ||
146 | checkAlarm->setAutoMask( FALSE ); | ||
147 | checkAlarm->setText( tr( "&Alarm" ) ); | ||
148 | checkAlarm->setChecked( FALSE ); | ||
149 | |||
150 | DateEntryBaseLayout->addWidget( checkAlarm, 8, 0 ); | ||
151 | |||
152 | spinAlarm = new QSpinBox( this, "spinAlarm" ); | ||
153 | spinAlarm->setEnabled( FALSE ); | ||
154 | spinAlarm->setSuffix( tr( " minutes" ) ); | ||
155 | spinAlarm->setMaxValue( 180 ); | ||
156 | spinAlarm->setMinValue( 0 ); | ||
157 | spinAlarm->setLineStep( 5 ); | ||
158 | spinAlarm->setValue( 5 ); | ||
159 | |||
160 | DateEntryBaseLayout->addMultiCellWidget( spinAlarm, 8, 8, 1, 2 ); | ||
161 | |||
162 | comboSound = new QComboBox( FALSE, this, "comboSound" ); | ||
163 | comboSound->insertItem( tr( "Silent" ) ); | ||
164 | comboSound->insertItem( tr( "Loud" ) ); | ||
165 | comboSound->setEnabled( FALSE ); | ||
166 | |||
167 | DateEntryBaseLayout->addWidget( comboSound, 8, 3 ); | ||
168 | |||
169 | lblRepeat = new QLabel( this, "lblRepeat" ); | ||
170 | lblRepeat->setText( tr( "Repeat" ) ); | ||
171 | |||
172 | DateEntryBaseLayout->addWidget( lblRepeat, 9, 0 ); | ||
173 | |||
174 | cmdRepeat = new QToolButton( this, "cmdRepeat" ); | ||
175 | cmdRepeat->setFocusPolicy( QToolButton::TabFocus ); | ||
176 | cmdRepeat->setText( tr( "No Repeat..." ) ); | ||
177 | cmdRepeat->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, cmdRepeat->sizePolicy().hasHeightForWidth() ) ); | ||
178 | |||
179 | DateEntryBaseLayout->addMultiCellWidget( cmdRepeat, 9, 9, 1, 3 ); | ||
180 | |||
181 | editNote = new QToolButton( this, "editNote" ); | ||
182 | editNote->setText( tr( "Note..." ) ); | ||
183 | |||
184 | DateEntryBaseLayout->addMultiCellWidget( editNote, 10, 10, 0, 3 ); | ||
185 | |||
186 | // signals and slots connections | ||
187 | connect( checkAlarm, SIGNAL( toggled(bool) ), spinAlarm, SLOT( setEnabled(bool) ) ); | ||
188 | connect( comboEnd, SIGNAL( textChanged(const QString&) ), this, SLOT( endTimeChanged( const QString & ) ) ); | ||
189 | connect( cmdRepeat, SIGNAL( clicked() ), this, SLOT( slotRepeat() ) ); | ||
190 | connect( comboStart, SIGNAL( textChanged(const QString &) ), this, SLOT( startTimeEdited( const QString & ) ) ); | ||
191 | connect( checkAllDay, SIGNAL( toggled(bool) ), comboEnd, SLOT( setDisabled(bool) ) ); | ||
192 | connect( checkAllDay, SIGNAL( toggled(bool) ), timePickerStart, SLOT( setDisabled(bool) ) ); | ||
193 | connect( checkAlarm, SIGNAL( toggled(bool) ), comboSound, SLOT( setEnabled(bool) ) ); | ||
194 | connect( checkAllDay, SIGNAL( toggled(bool) ), comboStart, SLOT( setDisabled(bool) ) ); | ||
195 | connect( checkAllDay, SIGNAL( toggled(bool) ), buttonEnd, SLOT( setDisabled(bool) ) ); | ||
196 | } | ||
197 | |||
198 | /* | ||
199 | * Destroys the object and frees any allocated resources | ||
200 | */ | ||
201 | DateEntryBase::~DateEntryBase() | ||
202 | { | ||
203 | // no need to delete child widgets, Qt does it all for us | ||
204 | } | ||
205 | |||
206 | void DateEntryBase::endDateChanged( const QString & ) | ||
207 | { | ||
208 | qWarning( "DateEntryBase::endDateChanged( const QString & ): Not implemented yet!" ); | ||
209 | } | ||
210 | |||
211 | void DateEntryBase::endDateChanged( int, int, int ) | ||
212 | { | ||
213 | qWarning( "DateEntryBase::endDateChanged( int, int, int ): Not implemented yet!" ); | ||
214 | } | ||
215 | |||
216 | void DateEntryBase::endTimeChanged( const QString & ) | ||
217 | { | ||
218 | qWarning( "DateEntryBase::endTimeChanged( const QString & ): Not implemented yet!" ); | ||
219 | } | ||
220 | |||
221 | void DateEntryBase::slotRepeat() | ||
222 | { | ||
223 | qWarning( "DateEntryBase::slotRepeat(): Not implemented yet!" ); | ||
224 | } | ||
225 | |||
226 | void DateEntryBase::slotWait( int ) | ||
227 | { | ||
228 | qWarning( "DateEntryBase::slotWait( int ): Not implemented yet!" ); | ||
229 | } | ||
230 | |||
231 | void DateEntryBase::startDateChanged( const QString & ) | ||
232 | { | ||
233 | qWarning( "DateEntryBase::startDateChanged( const QString & ): Not implemented yet!" ); | ||
234 | } | ||
235 | |||
236 | void DateEntryBase::startDateChanged(int, int, int) | ||
237 | { | ||
238 | qWarning( "DateEntryBase::startDateChanged(int, int, int): Not implemented yet!" ); | ||
239 | } | ||
240 | |||
241 | void DateEntryBase::startTimeEdited( const QString & ) | ||
242 | { | ||
243 | qWarning( "DateEntryBase::startTimeEdited( const QString & ): Not implemented yet!" ); | ||
244 | } | ||
245 | |||
246 | void DateEntryBase::typeChanged( const QString & ) | ||
247 | { | ||
248 | qWarning( "DateEntryBase::typeChanged( const QString & ): Not implemented yet!" ); | ||
249 | } | ||
250 | |||
251 | void DateEntryBase::tzexecute(void) | ||
252 | { | ||
253 | qWarning( "DateEntryBase::tzexecute(void): Not implemented yet!" ); | ||
254 | } | ||
255 | |||