File indexing completed on 2024-05-19 16:16:47

0001 /*
0002     SPDX-FileCopyrightText: 2006-2018 Thomas Baumgart <tbaumgart@kde.org>
0003     SPDX-FileCopyrightText: 2017-2018 Łukasz Wojniłowicz <lukasz.wojnilowicz@gmail.com>
0004     SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 #include <config-kmymoney.h>
0008 
0009 #include "fancydategroupmarker.h"
0010 #include "fancydategroupmarker_p.h"
0011 
0012 // ----------------------------------------------------------------------------
0013 // QT Includes
0014 
0015 // ----------------------------------------------------------------------------
0016 // KDE Includes
0017 
0018 #include <KLocalizedString>
0019 
0020 // ----------------------------------------------------------------------------
0021 // Project Includes
0022 #include "groupmarker.h"
0023 
0024 FancyDateGroupMarker::FancyDateGroupMarker(Register* parent,
0025         const QDate& date,
0026         const QString& txt) :
0027     GroupMarker(*new FancyDateGroupMarkerPrivate, parent, txt)
0028 {
0029     Q_D(FancyDateGroupMarker);
0030     d->m_date = date;
0031 }
0032 
0033 FancyDateGroupMarker::FancyDateGroupMarker(FancyDateGroupMarkerPrivate &dd, Register *parent, const QDate& date, const QString& txt) :
0034     GroupMarker(dd, parent, txt)
0035 {
0036     Q_D(FancyDateGroupMarker);
0037     d->m_date = date;
0038 }
0039 
0040 FancyDateGroupMarker::~FancyDateGroupMarker()
0041 {
0042 }
0043 
0044 QDate FancyDateGroupMarker::sortPostDate() const
0045 {
0046     Q_D(const FancyDateGroupMarker);
0047     return d->m_date;
0048 }
0049 
0050 QDate FancyDateGroupMarker::sortEntryDate() const
0051 {
0052     Q_D(const FancyDateGroupMarker);
0053     return d->m_date;
0054 }
0055 
0056 const char* FancyDateGroupMarker::className()
0057 {
0058     return "FancyDateGroupMarker";
0059 }