author | zautrix <zautrix> | 2005-04-14 17:48:58 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-04-14 17:48:58 (UTC) |
commit | bbdca90c599aaea557d31552c6bc33fc15e397cd (patch) (unidiff) | |
tree | e41b5eb16239664d2217e5436db61610099b60ef /libkdepim | |
parent | 5ea16ef9058a21016402dd5affc0a7f82857e606 (diff) | |
download | kdepimpi-bbdca90c599aaea557d31552c6bc33fc15e397cd.zip kdepimpi-bbdca90c599aaea557d31552c6bc33fc15e397cd.tar.gz kdepimpi-bbdca90c599aaea557d31552c6bc33fc15e397cd.tar.bz2 |
today added
-rw-r--r-- | libkdepim/kdateedit.cpp | 9 | ||||
-rw-r--r-- | libkdepim/kdateedit.h | 2 |
2 files changed, 11 insertions, 0 deletions
diff --git a/libkdepim/kdateedit.cpp b/libkdepim/kdateedit.cpp index 3d9e690..bf38479 100644 --- a/libkdepim/kdateedit.cpp +++ b/libkdepim/kdateedit.cpp | |||
@@ -70,2 +70,5 @@ KDateEdit::KDateEdit(QWidget *parent, const char *name, bool withoutDP ) | |||
70 | mDateButton->setPixmap(pixmap); | 70 | mDateButton->setPixmap(pixmap); |
71 | QPixmap pixmap2 = SmallIcon("today_small"); | ||
72 | QPushButton* nowButton = new QPushButton(this); | ||
73 | nowButton->setPixmap(pixmap2); | ||
71 | 74 | ||
@@ -84,2 +87,3 @@ KDateEdit::KDateEdit(QWidget *parent, const char *name, bool withoutDP ) | |||
84 | connect(mDateButton,SIGNAL(clicked()),SLOT(toggleDatePicker())); | 87 | connect(mDateButton,SIGNAL(clicked()),SLOT(toggleDatePicker())); |
88 | connect(nowButton,SIGNAL(clicked()),SLOT(goToNow())); | ||
85 | mDateButton->setFocusPolicy( QWidget::NoFocus ); | 89 | mDateButton->setFocusPolicy( QWidget::NoFocus ); |
@@ -134,2 +138,7 @@ void KDateEdit::clear() | |||
134 | } | 138 | } |
139 | void KDateEdit::goToNow() | ||
140 | { | ||
141 | setDate(QDate::currentDate() ); | ||
142 | emit setTimeTo( QTime::currentTime() ); | ||
143 | } | ||
135 | void KDateEdit::setDate(QDate newDate) | 144 | void KDateEdit::setDate(QDate newDate) |
diff --git a/libkdepim/kdateedit.h b/libkdepim/kdateedit.h index cf3b90a..2d8c452 100644 --- a/libkdepim/kdateedit.h +++ b/libkdepim/kdateedit.h | |||
@@ -89,2 +89,3 @@ class KDateEdit : public QHBox | |||
89 | void returnPressed(); | 89 | void returnPressed(); |
90 | void setTimeTo( QTime ); | ||
90 | public slots: | 91 | public slots: |
@@ -110,2 +111,3 @@ class KDateEdit : public QHBox | |||
110 | void textChanged(const QString &); | 111 | void textChanged(const QString &); |
112 | void goToNow(); | ||
111 | 113 | ||