Mailcommon

favoritecollectionwidget.h
1/*
2
3 SPDX-FileCopyrightText: 2012-2024 Laurent Montel <montel@kde.org>
4
5 SPDX-License-Identifier: GPL-2.0-or-later
6*/
7
8#pragma once
9
10#include "mailcommon_export.h"
11
12#include <Akonadi/EntityListView>
13
14class KXMLGUIClient;
16
17namespace MailCommon
18{
19class MailCommonSettings;
20/**
21 * @brief The FavoriteCollectionWidget class
22 * @author Laurent Montel <montel@kde.org>
23 */
24class MAILCOMMON_EXPORT FavoriteCollectionWidget : public Akonadi::EntityListView
25{
26 Q_OBJECT
27public:
28 explicit FavoriteCollectionWidget(MailCommon::MailCommonSettings *settings, KXMLGUIClient *xmlGuiClient, QWidget *parent = nullptr);
30
31 void readConfig();
32 void updateMode();
33
34 void changeViewMode(QListView::ViewMode mode);
35
36protected Q_SLOTS:
37 void slotGeneralFontChanged();
38 void slotGeneralPaletteChanged();
39 void slotChangeIconSize(bool);
40 void slotChangeMode(bool);
41
42protected:
43 void paintEvent(QPaintEvent *) override;
44 void dragEnterEvent(QDragEnterEvent *event) override;
45 void dragMoveEvent(QDragMoveEvent *event) override;
46 void dropEvent(QDropEvent *event) override;
47 void startDrag(Qt::DropActions) override;
48
49 void mousePressEvent(QMouseEvent *e) override;
50 [[nodiscard]] bool event(QEvent *e) override;
51Q_SIGNALS:
52 void newTabRequested(bool);
53
54private:
55 [[nodiscard]] bool acceptEvent(QDropEvent *event) const;
56 MAILCOMMON_NO_EXPORT void createMenu(KActionCollection *ac);
57 MAILCOMMON_NO_EXPORT void updatePalette();
58
59 class FavoriteCollectionWidgetPrivate;
60 std::unique_ptr<FavoriteCollectionWidgetPrivate> const d;
61};
62}
The FavoriteCollectionWidget class.
The filter dialog.
typedef DropActions
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 29 2024 11:58:44 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.