-rw-r--r-- | libkcal/recurrence.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libkcal/recurrence.h b/libkcal/recurrence.h index a0f6d84..b13d14f 100644 --- a/libkcal/recurrence.h +++ b/libkcal/recurrence.h @@ -267,54 +267,56 @@ class Recurrence * @var duration the number of times the event is to occur, or -1 to recur indefinitely. */ void setYearlyByDate(Feb29Type type, int freq, int duration); /** Sets an event to recur yearly ending at \a endDate. */ void setYearlyByDate(Feb29Type type, int freq, const QDate &endDate); /** Adds position of day or month in year. * N.B. for recursYearlyPos, addYearlyMonthPos() must also be called * to add positions within the month. */ void addYearlyNum(short _rNum); /** Adds a position to the recursYearlyPos recurrence rule, if it is set. * N.B. addYearlyNum() must also be called to add recurrence months. * Parameters are the same as for addMonthlyPos(). */ void addYearlyMonthPos(short _rPos, const QBitArray &_rDays); /** Returns positions of days or months in year. */ const QPtrList<int> &yearNums() const; /** Returns list of day positions in months, for a recursYearlyPos recurrence rule. */ const QPtrList<rMonthPos> &yearMonthPositions() const; /** Returns how yearly recurrences of February 29th are handled. */ Feb29Type feb29YearlyType() const { return mFeb29YearlyType; } /** Sets the default method for handling yearly recurrences of February 29th. */ static void setFeb29YearlyTypeDefault(Feb29Type t) { mFeb29YearlyDefaultType = t; } /** Returns the default method for handling yearly recurrences of February 29th. */ static Feb29Type setFeb29YearlyTypeDefault() { return mFeb29YearlyDefaultType; } - + void addYearlyMonth(short _rPos ); // added LR /** Debug output. */ void dump() const; QString recurrenceText() const; + bool getYearlyMonthMonths(int day, QValueList<int>&, + QValueList<int> &leaplist) const; protected: enum PeriodFunc { END_DATE_AND_COUNT, COUNT_TO_DATE, NEXT_AFTER_DATE }; struct MonthlyData; friend struct MonthlyData; struct YearlyMonthData; friend struct YearlyMonthData; struct YearlyPosData; friend struct YearlyPosData; struct YearlyDayData; friend struct YearlyDayData; bool recursSecondly(const QDate &, int secondFreq) const; bool recursMinutelyAt(const QDateTime &dt, int minuteFreq) const; bool recursDaily(const QDate &) const; bool recursWeekly(const QDate &) const; bool recursMonthly(const QDate &) const; bool recursYearlyByMonth(const QDate &) const; bool recursYearlyByPos(const QDate &) const; bool recursYearlyByDay(const QDate &) const; QDate getNextDateNoTime(const QDate& preDate, bool* last) const; QDate getPreviousDateNoTime(const QDate& afterDate, bool* last) const; void addMonthlyPos_(short _rPos, const QBitArray &_rDays); void setDailySub(short type, int freq, int duration); void setYearly_(short type, Feb29Type, int freq, int duration); int recurCalc(PeriodFunc, QDate &enddate) const; @@ -325,50 +327,48 @@ class Recurrence int weeklyCalcEndDate(QDate& enddate, int daysPerWeek) const; int weeklyCalcToDate(const QDate& enddate, int daysPerWeek) const; int weeklyCalcNextAfter(QDate& enddate, int daysPerWeek) const; int monthlyCalc(PeriodFunc, QDate &enddate) const; int monthlyCalcEndDate(QDate& enddate, MonthlyData&) const; int monthlyCalcToDate(const QDate& enddate, MonthlyData&) const; int monthlyCalcNextAfter(QDate& enddate, MonthlyData&) const; int yearlyMonthCalc(PeriodFunc, QDate &enddate) const; int yearlyMonthCalcEndDate(QDate& enddate, YearlyMonthData&) const; int yearlyMonthCalcToDate(const QDate& enddate, YearlyMonthData&) const; int yearlyMonthCalcNextAfter(QDate& enddate, YearlyMonthData&) const; int yearlyPosCalc(PeriodFunc, QDate &enddate) const; int yearlyPosCalcEndDate(QDate& enddate, YearlyPosData&) const; int yearlyPosCalcToDate(const QDate& enddate, YearlyPosData&) const; int yearlyPosCalcNextAfter(QDate& enddate, YearlyPosData&) const; int yearlyDayCalc(PeriodFunc, QDate &enddate) const; int yearlyDayCalcEndDate(QDate& enddate, YearlyDayData&) const; int yearlyDayCalcToDate(const QDate& enddate, YearlyDayData&) const; int yearlyDayCalcNextAfter(QDate& enddate, YearlyDayData&) const; int countMonthlyPosDays() const; void getMonthlyPosDays(QValueList<int>&, int daysInMonth, int startDayOfWeek) const; bool getMonthlyDayDays(QValueList<int>&, int daysInMonth) const; - bool getYearlyMonthMonths(int day, QValueList<int>&, - QValueList<int> &leaplist) const; int getFirstDayInWeek(int startDay, bool useWeekStart = true) const; int getLastDayInWeek(int endDay, bool useWeekStart = true) const; QDate getFirstDateInMonth(const QDate& earliestDate) const; QDate getLastDateInMonth(const QDate& latestDate) const; QDate getFirstDateInYear(const QDate& earliestDate) const; QDate getLastDateInYear(const QDate& latestDate) const; private: // Prohibit copying Recurrence(const Recurrence&); Recurrence &operator=(const Recurrence&); short recurs; // should be one of the enums. int rWeekStart; // day which starts the week, Monday=1 .. Sunday=7 QBitArray rDays; // array of days during week it recurs QPtrList<rMonthPos> rMonthPositions; // list of positions during a month // on which an event recurs QPtrList<int> rMonthDays; // list of days during a month on // which the event recurs |