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.
|
|
|
|
#include "OperatorsBase.h"
|
|
|
|
|
#include "GUIFrame/MainWindow.h"
|
|
|
|
|
#include "FITK_Kernel/FITKAppFramework/FITKAppFramework.h"
|
|
|
|
|
#include "FITK_Kernel/FITKAppFramework/FITKGlobalData.h"
|
|
|
|
|
#include "FITK_Kernel/FITKCore/FITKAbstractNDataObject.h"
|
|
|
|
|
|
|
|
|
|
#include <QAction>
|
|
|
|
|
|
|
|
|
|
namespace OperModel
|
|
|
|
|
{
|
|
|
|
|
/**
|
|
|
|
|
* @brief OperatorsBase的构造函数
|
|
|
|
|
*
|
|
|
|
|
* 该构造函数初始化OperatorsBase类的一个实例。它通过动态类型转换从FITKAPP的全局数据中获取GUI::MainWindow的指针,并将其赋值给_mainWindow成员变量。
|
|
|
|
|
*
|
|
|
|
|
* @param args 构造函数参数列表(当前未列出具体参数,表示可能有可选的参数传递给构造函数)
|
|
|
|
|
*/
|
|
|
|
|
OperatorsBase::OperatorsBase(/* args */)
|
|
|
|
|
{
|
|
|
|
|
_mainWindow = dynamic_cast<GUI::MainWindow *>(FITKAPP->getGlobalData()->getMainWindow());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @brief OperatorsBase的析构函数
|
|
|
|
|
*
|
|
|
|
|
* 该析构函数释放OperatorsBase类实例的资源,是一个空函数体。
|
|
|
|
|
*/
|
|
|
|
|
OperatorsBase::~OperatorsBase()
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void OperatorsBase::preArgs()
|
|
|
|
|
{
|
|
|
|
|
QAction* current = dynamic_cast<QAction*>(_emitter);
|
|
|
|
|
if (current == nullptr)return;
|
|
|
|
|
|
|
|
|
|
_isChecked = current->isChecked();
|
|
|
|
|
_senderName = current->objectName();
|
|
|
|
|
}
|
|
|
|
|
} // namespace ModelOper
|