File indexing completed on 2024-05-12 16:43:46

0001 /*
0002     SPDX-FileCopyrightText: 2000-2002 Michael Edwardes <mte@users.sourceforge.net>
0003     SPDX-FileCopyrightText: 2000-2002 Javier Campos Morales <javi_c@users.sourceforge.net>
0004     SPDX-FileCopyrightText: 2000-2002 Felix Rodriguez <frodriguez@users.sourceforge.net>
0005     SPDX-FileCopyrightText: 2000-2002 John C <thetacoturtle@users.sourceforge.net>
0006     SPDX-FileCopyrightText: 2000-2002 Thomas Baumgart <ipwizard@users.sourceforge.net>
0007     SPDX-FileCopyrightText: 2000-2002 Kevin Tambascio <ktambascio@users.sourceforge.net>
0008     SPDX-FileCopyrightText: 2017 Łukasz Wojniłowicz <lukasz.wojnilowicz@gmail.com>
0009     SPDX-License-Identifier: GPL-2.0-or-later
0010 */
0011 #ifndef KHOMEVIEW_H
0012 #define KHOMEVIEW_H
0013 
0014 // ----------------------------------------------------------------------------
0015 // QT Includes
0016 
0017 // ----------------------------------------------------------------------------
0018 // KDE Includes
0019 
0020 // ----------------------------------------------------------------------------
0021 // Project Includes
0022 
0023 #include "kmymoneyviewbase.h"
0024 
0025 /**
0026   * Displays a 'home page' for the user.  Similar to concepts used in
0027   * quicken and m$-money.
0028   *
0029   * @author Michael Edwardes
0030   *
0031   * @short A view containing the home page for kmymoney.
0032 **/
0033 
0034 class KHomeViewPrivate;
0035 class KHomeView : public KMyMoneyViewBase
0036 {
0037     Q_OBJECT
0038 
0039 public:
0040     explicit KHomeView(QWidget *parent = nullptr);
0041     ~KHomeView() override;
0042 
0043     void executeCustomAction(eView::Action action) override;
0044     void refresh();
0045 
0046 protected:
0047     void resizeEvent(QResizeEvent* event) override;
0048     void showEvent(QShowEvent* event) override;
0049     void wheelEvent(QWheelEvent *event) override;
0050     bool eventFilter(QObject* o, QEvent* e) override;
0051 
0052 public Q_SLOTS:
0053     /**
0054       * Print the current view
0055       */
0056     void slotPrintView();
0057 
0058 private:
0059     Q_DECLARE_PRIVATE(KHomeView)
0060 
0061 private Q_SLOTS:
0062     void slotOpenUrl(const QUrl &url);
0063     void slotAdjustScrollPos();
0064 };
0065 
0066 #endif