Updated the Tools menu to reflect current build.
[kdepim.git] / kalarm / reminder.h
blobe0804c50c22a954e83ee89dc5bc3c5595e7e63f7
1 /*
2 * reminder.h - reminder setting widget
3 * Program: kalarm
4 * Copyright © 2003-2005,2007-2009,2011 by David Jarvie <djarvie@kde.org>
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along
17 * with this program; if not, write to the Free Software Foundation, Inc.,
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21 #ifndef REMINDER_H
22 #define REMINDER_H
24 #include <QFrame>
26 class KDateTime;
27 class TimeSelector;
28 class CheckBox;
29 class ComboBox;
32 class Reminder : public QFrame
34 Q_OBJECT
35 public:
36 Reminder(const QString& reminderWhatsThis, const QString& valueWhatsThis,
37 const QString& beforeAfterWhatsThis, bool allowHourMinute,
38 bool showOnceOnly, QWidget* parent);
39 void setAfterOnly(bool after);
40 bool isReminder() const;
41 bool isOnceOnly() const;
42 int minutes() const;
43 void setMinutes(int minutes, bool dateOnly);
44 void setReadOnly(bool);
45 void setDateOnly(bool dateOnly);
46 void setMaximum(int hourmin, int days);
47 void setFocusOnCount();
48 void setOnceOnly(bool);
49 void enableOnceOnly(bool enable);
51 static QString i18n_chk_FirstRecurrenceOnly(); // text of 'Reminder for first recurrence only' checkbox
53 public slots:
54 void setDefaultUnits(const KDateTime&);
56 signals:
57 void changed();
59 private slots:
60 void slotReminderToggled(bool);
62 private:
63 TimeSelector* mTime;
64 CheckBox* mOnceOnly;
65 ComboBox* mTimeSignCombo;
66 bool mReadOnly; // the widget is read only
67 bool mOnceOnlyEnabled; // 'mOnceOnly' checkbox is allowed to be enabled
70 #endif // REMINDER_H
72 // vim: et sw=4: