summaryrefslogtreecommitdiff
path: root/core/pim/datebook/datebook.cpp
authorhakan <hakan>2002-03-26 19:05:31 (UTC)
committer hakan <hakan>2002-03-26 19:05:31 (UTC)
commit78211642003f70797a5faa1767a5ab2f5f83606f (patch) (unidiff)
tree703df6b1f8a98dbd00066ab3c21419b7f97e41b4 /core/pim/datebook/datebook.cpp
parentdbbbe1c0600422e4bd2d6a6aba271476f457ed97 (diff)
downloadopie-78211642003f70797a5faa1767a5ab2f5f83606f.zip
opie-78211642003f70797a5faa1767a5ab2f5f83606f.tar.gz
opie-78211642003f70797a5faa1767a5ab2f5f83606f.tar.bz2
Added shortcut buttons to set the start time
Diffstat (limited to 'core/pim/datebook/datebook.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/datebook/datebook.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/core/pim/datebook/datebook.cpp b/core/pim/datebook/datebook.cpp
index 92dbdc8..2deb96f 100644
--- a/core/pim/datebook/datebook.cpp
+++ b/core/pim/datebook/datebook.cpp
@@ -198,43 +198,54 @@ DateBook::DateBook( QWidget *parent, const char *, WFlags f )
198 198
199#if defined(Q_WS_QWS) && !defined(QT_NO_COP) 199#if defined(Q_WS_QWS) && !defined(QT_NO_COP)
200 connect( qApp, SIGNAL(appMessage(const QCString&, const QByteArray&)), 200 connect( qApp, SIGNAL(appMessage(const QCString&, const QByteArray&)),
201 this, SLOT(appMessage(const QCString&, const QByteArray&)) ); 201 this, SLOT(appMessage(const QCString&, const QByteArray&)) );
202#endif 202#endif
203 203
204 // listen on QPE/System 204 // listen on QPE/System
205#if defined(Q_WS_QWS) 205#if defined(Q_WS_QWS)
206#if !defined(QT_NO_COP) 206#if !defined(QT_NO_COP)
207 QCopChannel *channel = new QCopChannel( "QPE/System", this ); 207 QCopChannel *channel = new QCopChannel( "QPE/System", this );
208 connect( channel, SIGNAL(received(const QCString&, const QByteArray&)), 208 connect( channel, SIGNAL(received(const QCString&, const QByteArray&)),
209 this, SLOT(receive(const QCString&, const QByteArray&)) ); 209 this, SLOT(receive(const QCString&, const QByteArray&)) );
210 channel = new QCopChannel( "QPE/Datebook", this );
211 connect( channel, SIGNAL(received(const QCString&, const QByteArray&)),
212 this, SLOT(receive(const QCString&, const QByteArray&)) );
210#endif 213#endif
211#endif 214#endif
212 215
213 qDebug("done t=%d", t.elapsed() ); 216 qDebug("done t=%d", t.elapsed() );
214 217
215} 218}
216 219
217void DateBook::receive( const QCString &msg, const QByteArray &data ) 220void DateBook::receive( const QCString &msg, const QByteArray &data )
218{ 221{
219 QDataStream stream( data, IO_ReadOnly ); 222 QDataStream stream( data, IO_ReadOnly );
220 if ( msg == "timeChange(QString)" ) { 223 if ( msg == "timeChange(QString)" ) {
221 // update active view! 224 // update active view!
222 if ( dayAction->isOn() ) 225 if ( dayAction->isOn() )
223 viewDay(); 226 viewDay();
224 else if ( weekAction->isOn() ) 227 else if ( weekAction->isOn() )
225 viewWeek(); 228 viewWeek();
226 else if ( monthAction->isOn() ) 229 else if ( monthAction->isOn() )
227 viewMonth(); 230 viewMonth();
228 } 231 }
232 else if (msg == "editEvent(int)") {
233 /* Not yet working...
234 int uid;
235 stream >> uid;
236 Event e=db->getEvent(uid);
237 editEvent(e);
238 */
239 }
229} 240}
230 241
231DateBook::~DateBook() 242DateBook::~DateBook()
232{ 243{
233} 244}
234 245
235void DateBook::slotSettings() 246void DateBook::slotSettings()
236{ 247{
237 DateBookSettings frmSettings( ampm, this ); 248 DateBookSettings frmSettings( ampm, this );
238 frmSettings.setStartTime( startTime ); 249 frmSettings.setStartTime( startTime );
239 frmSettings.setAlarmPreset( aPreset, presetTime ); 250 frmSettings.setAlarmPreset( aPreset, presetTime );
240#if defined (Q_WS_QWS) || defined(_WS_QWS_) 251#if defined (Q_WS_QWS) || defined(_WS_QWS_)