2021-05-24 07:25:56 +00:00
|
|
|
/*
|
|
|
|
SPDX-FileCopyrightText: 2006 Albert Astals Cid <aacid@kde.org>
|
|
|
|
|
|
|
|
SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
|
|
|
|
#ifndef _EMBEDDEDFILESDIALOG_H_
|
|
|
|
#define _EMBEDDEDFILESDIALOG_H_
|
|
|
|
|
2014-10-19 13:28:32 +00:00
|
|
|
#include <QDialog>
|
2006-05-28 16:54:54 +00:00
|
|
|
|
2007-04-19 18:30:20 +00:00
|
|
|
class QTreeWidget;
|
2014-10-19 13:28:32 +00:00
|
|
|
class QPushButton;
|
2016-03-23 00:58:38 +00:00
|
|
|
class QTemporaryFile;
|
|
|
|
class QTreeWidgetItem;
|
2006-09-21 08:45:36 +00:00
|
|
|
|
|
|
|
namespace Okular
|
|
|
|
{
|
|
|
|
class Document;
|
|
|
|
class EmbeddedFile;
|
|
|
|
}
|
2006-05-28 16:54:54 +00:00
|
|
|
|
2014-10-19 13:28:32 +00:00
|
|
|
class EmbeddedFilesDialog : public QDialog
|
2006-05-28 16:54:54 +00:00
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2006-09-21 08:45:36 +00:00
|
|
|
EmbeddedFilesDialog(QWidget *parent, const Okular::Document *document);
|
2020-07-10 22:15:05 +00:00
|
|
|
|
2016-07-11 17:30:31 +00:00
|
|
|
private Q_SLOTS:
|
2020-02-20 14:48:08 +00:00
|
|
|
void saveFileFromButton();
|
2020-02-20 17:45:46 +00:00
|
|
|
void attachViewContextMenu();
|
2010-03-03 16:46:29 +00:00
|
|
|
void updateSaveButton();
|
2020-02-20 14:48:08 +00:00
|
|
|
void viewFileFromButton();
|
2019-12-20 15:40:59 +00:00
|
|
|
void viewFileItem(QTreeWidgetItem *item, int column);
|
2020-07-10 22:15:05 +00:00
|
|
|
|
2006-05-28 16:54:54 +00:00
|
|
|
private:
|
2007-07-03 15:30:44 +00:00
|
|
|
void saveFile(Okular::EmbeddedFile *);
|
2016-03-23 00:58:38 +00:00
|
|
|
void viewFile(Okular::EmbeddedFile *);
|
2020-07-10 22:15:05 +00:00
|
|
|
|
2006-05-28 16:54:54 +00:00
|
|
|
QTreeWidget *m_tw;
|
2020-07-10 22:15:05 +00:00
|
|
|
|
2016-10-29 09:13:24 +00:00
|
|
|
QPushButton *mUser1Button;
|
|
|
|
QPushButton *mUser2Button;
|
2016-03-23 00:58:38 +00:00
|
|
|
QList<QSharedPointer<QTemporaryFile>> m_openedFiles;
|
2006-05-28 16:54:54 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|