Messagelib

opensavedfilefolderwidget.h
1/*
2 SPDX-FileCopyrightText: 2014-2024 Laurent Montel <montel@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#pragma once
8
9#include <KMessageWidget>
10#include <QUrl>
11class QTimer;
12namespace MessageViewer
13{
14class OpenSavedFileFolderWidget : public KMessageWidget
15{
17public:
18 enum class FileType : uint8_t {
19 Attachment,
20 Pdf,
21 };
22
23 explicit OpenSavedFileFolderWidget(QWidget *parent = nullptr);
24 ~OpenSavedFileFolderWidget() override;
25
26 void setUrls(const QList<QUrl> &urls, MessageViewer::OpenSavedFileFolderWidget::FileType fileType);
27
28public Q_SLOTS:
29 void slotShowWarning();
30 void slotHideWarning();
31
32private:
33 void slotOpenSavedFileFolder();
34 void slotTimeOut();
35 void slotOpenFile();
36 void slotExplicitlyClosed();
37 QList<QUrl> mUrls;
38 QTimer *const mTimer;
39 QAction *const mShowFolderAction;
40 QAction *const mOpenFileAction;
41};
42}
Q_OBJECTQ_OBJECT
Q_SLOTSQ_SLOTS
QObject * parent() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:07:25 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.