You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
nmWTAI-Platform/Include/nmNum/nmSubWnd/nmSubWndGrid.h

54 lines
1.4 KiB
C++

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

#pragma once
#include "iSubWndBaseFit.h"
#include "nmSubWnd_global.h"
class nmWxGridVTKContainerWidget;
class QTimer;
class NM_SUB_WND_EXPORT nmSubWndGrid : public iSubWndBaseFit {
Q_OBJECT
public:
explicit nmSubWndGrid(QWidget *parent = 0, QString sExt = "",
double pebiGridControl = 150.0, bool bGeneratePebiGrid = true);
~nmSubWndGrid();
// 配置窗体
virtual void configWnd(QString sPrevInfo);
// 初始化UI
virtual void initUI();
virtual QWidget* initUiMainWx();
// 成果保存加载
virtual bool loadRsts();
virtual bool saveRsts();
virtual bool onConfirmClosing();
public slots:
void updateGrid();
void onDebounceTimeout();
void onPebiGridGenerated(bool success);
public:
// 执行命令通常来自Ribbon
virtual bool runCmdBy(QString sName, QString sID);
// 生成PEBI网格
bool generatePebiGrid();
private:
// UI布局和VTK控件
QVBoxLayout* m_mainLayout;
nmWxGridVTKContainerWidget* m_vtkWidget;
// 每个网格窗口独立持有防抖定时器避免多个窗口共享同一个static定时器导致刷新落到旧窗口
QTimer* m_pDebounceTimer;
// PEBI GridControl控制参数对应HX_NWTM_GRID_INPUT::GridControl
double m_dPebiGridControl;
// 是否根据当前地图几何重新生成PEBI网格
bool m_bGeneratePebiGrid;
};