4
4
Copyright (c) 2002 Cornelius Schumacher <schumacher@kde.org>
5
5
Copyright (C) 2003-2004 Reinhold Kainhofer <reinhold@kainhofer.com>
7
Copyright (C) 2010 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.net>
8
Author: Sergio Martins <sergio@kdab.com>
7
10
This program is free software; you can redistribute it and/or modify
8
11
it under the terms of the GNU General Public License as published by
9
12
the Free Software Foundation; either version 2 of the License, or
41
44
DateNavigator( QObject *parent = 0 );
44
KCal::DateList selectedDates();
47
KCalCore::DateList selectedDates();
46
49
int datesCount() const;
49
void selectDates( const KCal::DateList & );
52
void selectDates( const KCalCore::DateList &, const QDate &preferredMonth = QDate() );
50
53
void selectDate( const QDate & );
52
55
void selectDates( int count );
53
void selectDates( const QDate &, int count );
56
void selectDates( const QDate &, int count, const QDate &preferredMonth = QDate() );
56
void selectWeek( const QDate & );
59
void selectWeek( const QDate &, const QDate &preferredMonth = QDate() );
58
61
void selectWorkWeek();
59
62
void selectWorkWeek( const QDate & );
61
void selectWeekByDay( int weekDay, const QDate & );
64
void selectWeekByDay( int weekDay, const QDate &, const QDate &preferredMonth = QDate() );
63
66
void selectToday();
65
68
void selectPreviousYear();
66
void selectPreviousMonth();
69
void selectPreviousMonth( const QDate ¤tMonth = QDate(),
70
const QDate &selectionLowerLimit = QDate(),
71
const QDate &selectionUpperLimit = QDate() );
67
72
void selectPreviousWeek();
68
73
void selectNextWeek();
69
void selectNextMonth();
74
void selectNextMonth( const QDate ¤tMonth = QDate(),
75
const QDate &selectionLowerLimit = QDate(),
76
const QDate &selectionUpperLimit = QDate() );
70
77
void selectNextYear();
72
79
void selectPrevious();
76
83
void selectYear( int year );
79
void datesSelected( const KCal::DateList & );
86
/* preferredMonth is useful when the datelist crosses months,
87
if valid, any month-like component should honour it
89
void datesSelected( const KCalCore::DateList &, const QDate &preferredMonth );
92
void emitSelected( const QDate &preferredMonth = QDate() );
85
KCal::DateList mSelectedDates;
97
Selects next month if offset equals 1, or previous month
99
Bigger offsets are accepted.
101
void shiftMonth( const QDate &date,
102
const QDate &selectionLowerLimit,
103
const QDate &selectionUpperLimit,
106
KCalCore::DateList mSelectedDates;
109
MAX_SELECTABLE_DAYS = 50