Initial commit
This commit is contained in:
commit
b7d90b9afe
16245 files changed
+3396666
No files matched your search
@@ -0,0 +1,84 @@
|
||||
/**
|
||||
* @RDE_HEADER@
|
||||
* HMI Plugin for Observer Controller - PDF Folder Content
|
||||
* $Id$
|
||||
* $HeadURL$
|
||||
* $Author$
|
||||
* Created by Steve Kemayou, SLSE, 2022-07-07
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <LtsWidgets/lts_dialog.h>
|
||||
#include <OcSituationClient/logger.h>
|
||||
#include <Plugins/OcSituationClient/osc_data_plugin_interface.h>
|
||||
#include <LtsSession/lts_session.h>
|
||||
#include <QFileSystemModel>
|
||||
#include <nglwidgets/nglpdfwidget.h>
|
||||
#include <QSortFilterProxyModel>
|
||||
#include <LtsUtilsGuiDds/request_helper.h>
|
||||
|
||||
#include <Plugins/OcBaseDownload/obd_data_plugin_interface.h>
|
||||
|
||||
|
||||
#define ZOOM_DEFAULT 1.0
|
||||
namespace Ui {
|
||||
class FolderContentEditDialog;
|
||||
}
|
||||
|
||||
namespace OcSituationClient
|
||||
{
|
||||
class FolderContentEditDialog : public LtsWidgets::LtsDialog
|
||||
, protected OcBaseDownload::Interface::Ftc::OcPdfDownloadReplyHandler
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit FolderContentEditDialog(QWidget *parent = nullptr);
|
||||
~FolderContentEditDialog();
|
||||
bool init(LtsSession::LtsSessionDataDds *session);
|
||||
void setDefaultFileSystemPath(QString path = QStringLiteral(""));
|
||||
QString getFileSysPath(){return m_filesysPath;}
|
||||
void initPdfWidow();
|
||||
|
||||
|
||||
void onOcPdfDownloadReply(const Core::FunctionReplyObject &replyObject) override final;
|
||||
|
||||
private slots:
|
||||
void onDeleteFile();
|
||||
void onPreviewFile();
|
||||
void setPage(int pageNo);
|
||||
int getNumPages() const;
|
||||
int getCurPage() const;
|
||||
void setZoomFactor(double zoomFactor);
|
||||
void setRotation(int rotation);
|
||||
void onSelectionChanged();
|
||||
void onOcPdfDownloadClicked();
|
||||
|
||||
signals:
|
||||
void currentPageChanged(int curPage);
|
||||
void rotationChanged(int rotation);
|
||||
|
||||
private:
|
||||
void retranslate();
|
||||
void enaDisa();
|
||||
|
||||
|
||||
Ui::FolderContentEditDialog *m_ui;
|
||||
LtsSession::LtsSessionDataDds *m_session;
|
||||
std::shared_ptr<OcBaseDownload::Interface::Ftc> m_obdFtc;
|
||||
|
||||
QFileSystemModel *m_fileSystemModel{nullptr};
|
||||
QString m_filesysPath{};
|
||||
NGL::PDFWidget *m_pdfWidget{nullptr};
|
||||
int m_pageNo{-1};
|
||||
double m_zoomFactor{ZOOM_DEFAULT};
|
||||
int m_rotation; // degree
|
||||
QSortFilterProxyModel *m_proxymodel;
|
||||
QString m_currViewPath;
|
||||
QSortFilterProxyModel *m_sortProxyModel{nullptr};
|
||||
LtsUtils::RequestHelper *m_requestHelper{nullptr};
|
||||
LOGGER_T m_logger;
|
||||
};
|
||||
|
||||
}// namespace FileManagement
|
||||
Reference in new issue
Block a user