Compare commits
No commits in common. "c981553536bf2e9babced9f614fb52db4d2b683b" and "b464eb94e93a63fa2a63784dc880109a52e07a06" have entirely different histories.
c981553536
...
b464eb94e9
|
|
@ -113,7 +113,6 @@ public:
|
||||||
QScrollArea *m_pDialogLayout;
|
QScrollArea *m_pDialogLayout;
|
||||||
PaiPushButton *m_pbtnRun;
|
PaiPushButton *m_pbtnRun;
|
||||||
QString m_CurrentSLFFileName;
|
QString m_CurrentSLFFileName;
|
||||||
QToolBar *m_toolBar_plugin = NULL;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -66,11 +66,6 @@ BEGIN_OSGGRAPHICS_NAMESPACE;
|
||||||
//关闭事件
|
//关闭事件
|
||||||
void CModuleParamers::closeEvent(QCloseEvent *event)
|
void CModuleParamers::closeEvent(QCloseEvent *event)
|
||||||
{
|
{
|
||||||
if (m_toolBar_plugin)
|
|
||||||
{
|
|
||||||
m_toolBar_plugin->clear();
|
|
||||||
m_toolBar_plugin->hide();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//构造函数
|
//构造函数
|
||||||
|
|
|
||||||
|
|
@ -1350,27 +1350,8 @@ void WorkflowSceneManager::slotAddModule(const QString& moduleName)
|
||||||
// pai::objectmodel::PaiWorkflowDataModel* pWorkflow = pModuleConsole->m_pWorkflowDataModel;
|
// pai::objectmodel::PaiWorkflowDataModel* pWorkflow = pModuleConsole->m_pWorkflowDataModel;
|
||||||
// ::GetWorkflowConsole()->GetWorkflowWidget()->SetWorkflow(pWorkflow);
|
// ::GetWorkflowConsole()->GetWorkflowWidget()->SetWorkflow(pWorkflow);
|
||||||
}
|
}
|
||||||
// Plugin ToolBar工具栏
|
|
||||||
if (pModuleParamers->m_toolBar_plugin)
|
|
||||||
pModuleParamers->m_toolBar_plugin->hide();
|
|
||||||
|
|
||||||
if(amodule&&amodule->parDialog) {
|
if(amodule&&amodule->parDialog) {
|
||||||
|
|
||||||
if (pModuleParamers->m_toolBar_plugin->isHidden())
|
|
||||||
{
|
|
||||||
// 从插件里获取QAction 显示在Plugin ToolBar工具栏
|
|
||||||
pModuleParamers->m_toolBar_plugin->clear();
|
|
||||||
for (int i = 0; i < amodule->m_listAct.size(); i++)
|
|
||||||
{
|
|
||||||
QAction* pAct = amodule->m_listAct.at(i);
|
|
||||||
QString sicon = pAct->property("icon_v").toString();
|
|
||||||
QIcon imIcon(::GetImagePath() + sicon);
|
|
||||||
pAct->setIcon(imIcon);
|
|
||||||
pModuleParamers->m_toolBar_plugin->addAction(pAct);
|
|
||||||
}
|
|
||||||
pModuleParamers->m_toolBar_plugin->show();
|
|
||||||
}
|
|
||||||
|
|
||||||
QRect rt=amodule->parDialog->geometry();
|
QRect rt=amodule->parDialog->geometry();
|
||||||
pModuleParamers->m_pParameterEditor->setVisible(false);
|
pModuleParamers->m_pParameterEditor->setVisible(false);
|
||||||
pModuleParamers->m_pDialogLayout->setVisible(true);
|
pModuleParamers->m_pDialogLayout->setVisible(true);
|
||||||
|
|
|
||||||
|
|
@ -110,7 +110,6 @@ public:
|
||||||
struct LogType *pLogType;
|
struct LogType *pLogType;
|
||||||
struct ErrorInf *errorinf;
|
struct ErrorInf *errorinf;
|
||||||
QDialog *parDialog;
|
QDialog *parDialog;
|
||||||
QList<QAction*> m_listAct;
|
|
||||||
QStringList OriginInNames;
|
QStringList OriginInNames;
|
||||||
QStringList OriginOutNames;
|
QStringList OriginOutNames;
|
||||||
bool InitModule(QWidget*p=NULL);
|
bool InitModule(QWidget*p=NULL);
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,6 @@
|
||||||
#include "ObjWelllogRound.h"
|
#include "ObjWelllogRound.h"
|
||||||
#include "ParameterItem.h"
|
#include "ParameterItem.h"
|
||||||
#include <QTextCodec>
|
#include <QTextCodec>
|
||||||
#include <QAction>
|
|
||||||
// void OSGFRAMEWORK_EXPORT AppendConsole(pai::log::Priority priority,const QString &output);
|
// void OSGFRAMEWORK_EXPORT AppendConsole(pai::log::Priority priority,const QString &output);
|
||||||
|
|
||||||
using namespace pai::module;
|
using namespace pai::module;
|
||||||
|
|
@ -1232,8 +1231,6 @@ bool PELibraryModule::validate()
|
||||||
bool PELibraryModule::InitModule(QWidget*pWidget)
|
bool PELibraryModule::InitModule(QWidget*pWidget)
|
||||||
{
|
{
|
||||||
typedef QDialog *(* LPDDIALOG)(QWidget*pWidget);
|
typedef QDialog *(* LPDDIALOG)(QWidget*pWidget);
|
||||||
typedef void* (*LPD_ACTION_FUNC)(int* count);
|
|
||||||
|
|
||||||
typedef int (* LPFNDLLFUNC)();
|
typedef int (* LPFNDLLFUNC)();
|
||||||
LPFNDLLFUNC lpfnDllFunc,lpfnInitDllFunc;
|
LPFNDLLFUNC lpfnDllFunc,lpfnInitDllFunc;
|
||||||
LPDDIALOG m_parDialog;
|
LPDDIALOG m_parDialog;
|
||||||
|
|
@ -1293,19 +1290,6 @@ bool PELibraryModule::InitModule(QWidget*pWidget)
|
||||||
if(m_parDialog) {
|
if(m_parDialog) {
|
||||||
if(errorinf) errorinf->ErrorNo=0;
|
if(errorinf) errorinf->ErrorNo=0;
|
||||||
parDialog=m_parDialog(pWidget);
|
parDialog=m_parDialog(pWidget);
|
||||||
|
|
||||||
LPD_ACTION_FUNC ACT_Func = (LPD_ACTION_FUNC)Methodlib.resolve("getAction_CApi");
|
|
||||||
if (ACT_Func)
|
|
||||||
{
|
|
||||||
int ncount = 0;
|
|
||||||
QAction** actArr = (QAction**)ACT_Func(&ncount);
|
|
||||||
for (int i = 0; i < ncount; i++)
|
|
||||||
{
|
|
||||||
QAction* pAct = actArr[i];
|
|
||||||
QString s = pAct->property("icon_v").toString();
|
|
||||||
m_listAct << actArr[i];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if(errorinf) {
|
if(errorinf) {
|
||||||
if(errorinf->ErrorNo<0) {
|
if(errorinf->ErrorNo<0) {
|
||||||
if(parDialog) {
|
if(parDialog) {
|
||||||
|
|
|
||||||
|
|
@ -73,7 +73,6 @@ SOURCES += \
|
||||||
mainwindow.cpp \
|
mainwindow.cpp \
|
||||||
main.cpp \
|
main.cpp \
|
||||||
mainwindowcurve.cpp \
|
mainwindowcurve.cpp \
|
||||||
mainwindowsplitter.cpp \
|
|
||||||
newheaddialog.cpp \
|
newheaddialog.cpp \
|
||||||
preqtablewidget.cpp \
|
preqtablewidget.cpp \
|
||||||
qmycustomplot.cpp \
|
qmycustomplot.cpp \
|
||||||
|
|
@ -136,7 +135,6 @@ HEADERS += \
|
||||||
fracsel.h \
|
fracsel.h \
|
||||||
mainwindow.h \
|
mainwindow.h \
|
||||||
mainwindowcurve.h \
|
mainwindowcurve.h \
|
||||||
mainwindowsplitter.h \
|
|
||||||
newheaddialog.h \
|
newheaddialog.h \
|
||||||
preqtablewidget.h \
|
preqtablewidget.h \
|
||||||
qmycustomplot.h \
|
qmycustomplot.h \
|
||||||
|
|
@ -166,7 +164,6 @@ FORMS += \
|
||||||
interfaceWidget.ui \
|
interfaceWidget.ui \
|
||||||
mainwindow.ui \
|
mainwindow.ui \
|
||||||
mainwindowcurve.ui \
|
mainwindowcurve.ui \
|
||||||
mainwindowsplitter.ui \
|
|
||||||
newheaddialog.ui \
|
newheaddialog.ui \
|
||||||
qtprojectwidgets.ui
|
qtprojectwidgets.ui
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -24,8 +24,6 @@
|
||||||
#include "TxtEditorDlg.h"
|
#include "TxtEditorDlg.h"
|
||||||
#include "ObjWell.h"
|
#include "ObjWell.h"
|
||||||
#include "wellloginformation.h"
|
#include "wellloginformation.h"
|
||||||
#include "mainwindowsplitter.h"
|
|
||||||
|
|
||||||
using namespace pai::gui;
|
using namespace pai::gui;
|
||||||
//以下参数从配置文件读取
|
//以下参数从配置文件读取
|
||||||
int g_iIndex = 0;
|
int g_iIndex = 0;
|
||||||
|
|
@ -340,11 +338,6 @@ void MainWindow::s_Open()
|
||||||
|
|
||||||
void MainWindow::s_SaveProject()
|
void MainWindow::s_SaveProject()
|
||||||
{
|
{
|
||||||
QWidget * pMyWidget = CallPlugin::getInstance()->getPluginWidget(DEMO_PLUGIN, (QWidget *)this);
|
|
||||||
if (pMyWidget != nullptr)
|
|
||||||
{
|
|
||||||
pMyWidget->show();
|
|
||||||
}
|
|
||||||
// //加载插件显示
|
// //加载插件显示
|
||||||
// QWidget * pMyWidget = CallPlugin::getInstance()->getPluginWidget(PLUGINUNIT, (QWidget *)this);
|
// QWidget * pMyWidget = CallPlugin::getInstance()->getPluginWidget(PLUGINUNIT, (QWidget *)this);
|
||||||
// if (pMyWidget != nullptr)
|
// if (pMyWidget != nullptr)
|
||||||
|
|
@ -401,14 +394,11 @@ void MainWindow::s_showView()
|
||||||
tr("多井图文件(*.json)"));
|
tr("多井图文件(*.json)"));
|
||||||
if (fileFull.isEmpty())
|
if (fileFull.isEmpty())
|
||||||
{
|
{
|
||||||
MainWindowSplitter* mainSplitter = new MainWindowSplitter();
|
|
||||||
mainSplitter->setSplitterWidget(m_projectWidgets);
|
|
||||||
m_centerWidgets->addTab(mainSplitter, "解释视图");
|
|
||||||
//----
|
//----
|
||||||
// MainWindowCurve *mainWindowCurve = new MainWindowCurve();//中间工作区
|
MainWindowCurve *mainWindowCurve = new MainWindowCurve();//中间工作区
|
||||||
// // 左侧树
|
// 左侧树
|
||||||
// mainWindowCurve->m_leftWidgets = m_projectWidgets;
|
mainWindowCurve->m_leftWidgets = m_projectWidgets;
|
||||||
// m_centerWidgets->addTab(mainWindowCurve, "解释视图");
|
m_centerWidgets->addTab(mainWindowCurve, "解释视图");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -416,16 +406,10 @@ void MainWindow::s_showView()
|
||||||
QString fileName = fileInfo.fileName(); // 获取文件名
|
QString fileName = fileInfo.fileName(); // 获取文件名
|
||||||
|
|
||||||
//----
|
//----
|
||||||
//MainWindowCurve *mainWindowCurve = new MainWindowCurve();//中间工作区
|
MainWindowCurve *mainWindowCurve = new MainWindowCurve();//中间工作区
|
||||||
//// 左侧树
|
// 左侧树
|
||||||
//mainWindowCurve->m_leftWidgets = m_projectWidgets;
|
mainWindowCurve->m_leftWidgets = m_projectWidgets;
|
||||||
//m_centerWidgets->addTab(mainWindowCurve, fileName);
|
m_centerWidgets->addTab(mainWindowCurve, fileName);
|
||||||
|
|
||||||
MainWindowSplitter* mainSplitter = new MainWindowSplitter();
|
|
||||||
mainSplitter->setSplitterWidget(m_projectWidgets);
|
|
||||||
m_centerWidgets->addTab(mainSplitter, fileName);
|
|
||||||
|
|
||||||
MainWindowCurve *mainWindowCurve = mainSplitter->getMainWindowCurve();
|
|
||||||
mainWindowCurve->Open(fileFull);
|
mainWindowCurve->Open(fileFull);
|
||||||
|
|
||||||
//QFuture<void> future = QtConcurrent::run(std::bind(&MainWindowCurve::s_Open, mainWindowCurve, fileFull));
|
//QFuture<void> future = QtConcurrent::run(std::bind(&MainWindowCurve::s_Open, mainWindowCurve, fileFull));
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,6 @@
|
||||||
#include "LogModuleParamers.h"
|
#include "LogModuleParamers.h"
|
||||||
#include "LogModuleConsole.h"
|
#include "LogModuleConsole.h"
|
||||||
#include "DepPairs.h"
|
#include "DepPairs.h"
|
||||||
#include "mainwindowsplitter.h"
|
|
||||||
|
|
||||||
extern int g_iOneWidth; //道宽
|
extern int g_iOneWidth; //道宽
|
||||||
extern QString g_prjname;
|
extern QString g_prjname;
|
||||||
|
|
@ -35,8 +34,6 @@ MainWindowCurve::MainWindowCurve(QWidget *parent) :
|
||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
|
||||||
m_pParentWin = qobject_cast<MainWindowSplitter*>(parent);
|
|
||||||
|
|
||||||
QtCommonClass *qtCommon = new QtCommonClass(this);
|
QtCommonClass *qtCommon = new QtCommonClass(this);
|
||||||
m_strUuid = qtCommon->getUUid();
|
m_strUuid = qtCommon->getUUid();
|
||||||
|
|
||||||
|
|
@ -44,7 +41,6 @@ MainWindowCurve::MainWindowCurve(QWidget *parent) :
|
||||||
addToolBar(Qt::LeftToolBarArea, ui->toolBar);
|
addToolBar(Qt::LeftToolBarArea, ui->toolBar);
|
||||||
addToolBar(Qt::RightToolBarArea, ui->toolBar_2);
|
addToolBar(Qt::RightToolBarArea, ui->toolBar_2);
|
||||||
addToolBar(Qt::RightToolBarArea, ui->toolBar_3);
|
addToolBar(Qt::RightToolBarArea, ui->toolBar_3);
|
||||||
addToolBar(Qt::RightToolBarArea, ui->toolBar_plugin);
|
|
||||||
|
|
||||||
//初始化工具栏
|
//初始化工具栏
|
||||||
initMainToolBar();
|
initMainToolBar();
|
||||||
|
|
@ -55,7 +51,7 @@ MainWindowCurve::MainWindowCurve(QWidget *parent) :
|
||||||
//拼接
|
//拼接
|
||||||
initToolBar_3();
|
initToolBar_3();
|
||||||
ui->toolBar_3->hide();
|
ui->toolBar_3->hide();
|
||||||
ui->toolBar_plugin->hide();
|
|
||||||
//加载样式
|
//加载样式
|
||||||
loadStyle(":/qrc/qss/flatgray.css");
|
loadStyle(":/qrc/qss/flatgray.css");
|
||||||
|
|
||||||
|
|
@ -162,11 +158,6 @@ MainWindowCurve::~MainWindowCurve()
|
||||||
delete ui;
|
delete ui;
|
||||||
}
|
}
|
||||||
|
|
||||||
QToolBar * MainWindowCurve::getPluginToolBar()
|
|
||||||
{
|
|
||||||
return ui->toolBar_plugin;
|
|
||||||
}
|
|
||||||
|
|
||||||
//鼠标滚动,通知可视解释窗口
|
//鼠标滚动,通知可视解释窗口
|
||||||
void MainWindowCurve::s_mouseWheel(QWheelEvent *event)
|
void MainWindowCurve::s_mouseWheel(QWheelEvent *event)
|
||||||
{
|
{
|
||||||
|
|
@ -229,7 +220,6 @@ void MainWindowCurve::initMainToolBar()
|
||||||
ui->mainToolBar->addAction(m_executeDepthShiftAc);
|
ui->mainToolBar->addAction(m_executeDepthShiftAc);
|
||||||
ui->mainToolBar->addAction(m_joindepthAc);
|
ui->mainToolBar->addAction(m_joindepthAc);
|
||||||
ui->mainToolBar->addAction(m_ModuleOpenAc);
|
ui->mainToolBar->addAction(m_ModuleOpenAc);
|
||||||
|
|
||||||
// ui->mainToolBar->addAction(m_runAc);
|
// ui->mainToolBar->addAction(m_runAc);
|
||||||
// ui->mainToolBar->addAction(m_debugAc);
|
// ui->mainToolBar->addAction(m_debugAc);
|
||||||
// ui->mainToolBar->addAction(m_loadAc);
|
// ui->mainToolBar->addAction(m_loadAc);
|
||||||
|
|
@ -2308,7 +2298,41 @@ void MainWindowCurve::s_ExecuteMerge()
|
||||||
|
|
||||||
void MainWindowCurve::s_ModuleOpen()
|
void MainWindowCurve::s_ModuleOpen()
|
||||||
{
|
{
|
||||||
m_pParentWin->setModuleOpenOrClose();
|
QString strSlfName = "";
|
||||||
|
QString strLeft = m_leftWidgets->getLeftTreeString();
|
||||||
|
if(strLeft.length() > 0)
|
||||||
|
{
|
||||||
|
QStringList list = strLeft.split("#@@#");//QString字符串分割函数
|
||||||
|
if (list.size() > 3)
|
||||||
|
{
|
||||||
|
strSlfName = list[0];
|
||||||
|
QString strWellName = list[1];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (strSlfName.isEmpty())
|
||||||
|
{
|
||||||
|
QMessageBox::information(nullptr, "提示", "请先选中待处理井次");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
CModuleConsole* pModuleConsole = new pai::graphics::CModuleConsole();
|
||||||
|
CModuleParamers* pDialog = new CModuleParamers(pModuleConsole);//::CreatParamControlWidget();
|
||||||
|
SetWorkflowConsole(pModuleConsole);
|
||||||
|
pModuleConsole->g_mModuleParamers = pDialog;
|
||||||
|
pModuleConsole->m_pWorkflowDataModel = new CWellLogWorkflowDataModel();
|
||||||
|
pDialog->m_CurrentSLFFileName = strSlfName;
|
||||||
|
pDialog->CreatParamControlWidget();
|
||||||
|
|
||||||
|
QString subStr = strSlfName;
|
||||||
|
int startPos = strSlfName.indexOf("Logdata");
|
||||||
|
if (startPos>=0)
|
||||||
|
{
|
||||||
|
subStr = subStr.right(strSlfName.length() - startPos - 7);
|
||||||
|
}
|
||||||
|
pDialog->setWindowTitle(subStr);
|
||||||
|
|
||||||
|
pDialog->show();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
//void MainWindowCurve::s_Open(QString fileFull)
|
//void MainWindowCurve::s_Open(QString fileFull)
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,6 @@ struct SelectTableItem
|
||||||
QString m_strLineName="";
|
QString m_strLineName="";
|
||||||
QString m_strFormInfoType="";//类型:curve, wave
|
QString m_strFormInfoType="";//类型:curve, wave
|
||||||
};
|
};
|
||||||
class MainWindowSplitter;
|
|
||||||
|
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
class MainWindowCurve;
|
class MainWindowCurve;
|
||||||
|
|
@ -35,7 +34,6 @@ public:
|
||||||
explicit MainWindowCurve(QWidget *parent = nullptr);
|
explicit MainWindowCurve(QWidget *parent = nullptr);
|
||||||
~MainWindowCurve();
|
~MainWindowCurve();
|
||||||
|
|
||||||
QToolBar * getPluginToolBar();
|
|
||||||
private:
|
private:
|
||||||
Ui::MainWindowCurve *ui;
|
Ui::MainWindowCurve *ui;
|
||||||
|
|
||||||
|
|
@ -54,8 +52,6 @@ public slots:
|
||||||
void s_mouseWheel(QWheelEvent *event);
|
void s_mouseWheel(QWheelEvent *event);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
MainWindowSplitter* m_pParentWin = NULL;
|
|
||||||
|
|
||||||
QString m_strUuid;
|
QString m_strUuid;
|
||||||
QStringList m_listWell;
|
QStringList m_listWell;
|
||||||
//当前选中数据表格
|
//当前选中数据表格
|
||||||
|
|
|
||||||
|
|
@ -15,9 +15,6 @@
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="centralwidget">
|
<widget class="QWidget" name="centralwidget">
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<property name="rightMargin">
|
|
||||||
<number>3</number>
|
|
||||||
</property>
|
|
||||||
<item row="1" column="1">
|
<item row="1" column="1">
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
<item>
|
<item>
|
||||||
|
|
@ -33,7 +30,7 @@
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>800</width>
|
<width>800</width>
|
||||||
<height>23</height>
|
<height>21</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
|
|
@ -82,17 +79,6 @@
|
||||||
<bool>false</bool>
|
<bool>false</bool>
|
||||||
</attribute>
|
</attribute>
|
||||||
</widget>
|
</widget>
|
||||||
<widget class="QToolBar" name="toolBar_plugin">
|
|
||||||
<property name="windowTitle">
|
|
||||||
<string>toolBar_4</string>
|
|
||||||
</property>
|
|
||||||
<attribute name="toolBarArea">
|
|
||||||
<enum>TopToolBarArea</enum>
|
|
||||||
</attribute>
|
|
||||||
<attribute name="toolBarBreak">
|
|
||||||
<bool>false</bool>
|
|
||||||
</attribute>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
</widget>
|
||||||
<resources/>
|
<resources/>
|
||||||
<connections/>
|
<connections/>
|
||||||
|
|
|
||||||
|
|
@ -1,76 +0,0 @@
|
||||||
#include "mainwindowsplitter.h"
|
|
||||||
#include "ui_mainwindowsplitter.h"
|
|
||||||
#include "LogModuleParamers.h"
|
|
||||||
#include "LogModuleConsole.h"
|
|
||||||
|
|
||||||
MainWindowSplitter::MainWindowSplitter(QWidget *parent) :
|
|
||||||
QMainWindow(parent),
|
|
||||||
ui(new Ui::MainWindowSplitter)
|
|
||||||
{
|
|
||||||
ui->setupUi(this);
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
MainWindowSplitter::~MainWindowSplitter()
|
|
||||||
{
|
|
||||||
delete ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
void MainWindowSplitter::setSplitterWidget(QtProjectWidgets *pWidgets)
|
|
||||||
{
|
|
||||||
m_mainWindowCurve = new MainWindowCurve(this);//中间工作区
|
|
||||||
// 左侧树
|
|
||||||
m_mainWindowCurve->m_leftWidgets = pWidgets;
|
|
||||||
m_PluginToolBar = m_mainWindowCurve->getPluginToolBar();
|
|
||||||
|
|
||||||
CModuleConsole* pModuleConsole = new pai::graphics::CModuleConsole();
|
|
||||||
CModuleParamers* pDialog = new CModuleParamers(pModuleConsole);//::CreatParamControlWidget();
|
|
||||||
SetWorkflowConsole(pModuleConsole);
|
|
||||||
pModuleConsole->g_mModuleParamers = pDialog;
|
|
||||||
pModuleConsole->m_pWorkflowDataModel = new CWellLogWorkflowDataModel();
|
|
||||||
//pDialog->m_CurrentSLFFileName = strSlfName;
|
|
||||||
pDialog->m_toolBar_plugin = m_PluginToolBar;
|
|
||||||
pDialog->CreatParamControlWidget();
|
|
||||||
|
|
||||||
//QString subStr = strSlfName;
|
|
||||||
//int startPos = strSlfName.indexOf("Logdata");
|
|
||||||
//if (startPos >= 0)
|
|
||||||
//{
|
|
||||||
// subStr = subStr.right(strSlfName.length() - startPos - 7);
|
|
||||||
//}
|
|
||||||
//pDialog->setWindowTitle(subStr);
|
|
||||||
|
|
||||||
//pDialog->show();
|
|
||||||
|
|
||||||
m_pVSplitter = new QSplitter(Qt::Horizontal);
|
|
||||||
|
|
||||||
m_pVSplitter->addWidget(m_mainWindowCurve);
|
|
||||||
m_pVSplitter->addWidget(pDialog);
|
|
||||||
|
|
||||||
setCentralWidget(m_pVSplitter);
|
|
||||||
|
|
||||||
QList<int> sizes;
|
|
||||||
sizes << this->width() << 0;
|
|
||||||
m_pVSplitter->setSizes(sizes);//默认隐藏左侧多井图窗口
|
|
||||||
}
|
|
||||||
|
|
||||||
void MainWindowSplitter::setModuleOpenOrClose()
|
|
||||||
{
|
|
||||||
QList<int> sizes;
|
|
||||||
if (m_pVSplitter->widget(1)->width()) {
|
|
||||||
sizes << width() << 0;
|
|
||||||
if (m_PluginToolBar)
|
|
||||||
m_PluginToolBar->hide();
|
|
||||||
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
sizes << width() - 450 << 450;
|
|
||||||
}
|
|
||||||
m_pVSplitter->setSizes(sizes);//默认隐藏左侧多井图窗口
|
|
||||||
}
|
|
||||||
|
|
||||||
MainWindowCurve* MainWindowSplitter::getMainWindowCurve()
|
|
||||||
{
|
|
||||||
return m_mainWindowCurve;
|
|
||||||
}
|
|
||||||
|
|
@ -1,47 +0,0 @@
|
||||||
#ifndef MainWindowSplitter_H
|
|
||||||
#define MainWindowSplitter_H
|
|
||||||
|
|
||||||
#include <QMainWindow>
|
|
||||||
#include "mainwindowcurve.h"
|
|
||||||
#include "qtprojectwidgets.h"
|
|
||||||
|
|
||||||
|
|
||||||
#pragma execution_character_set("utf-8")
|
|
||||||
|
|
||||||
namespace Ui {
|
|
||||||
class MainWindowSplitter;
|
|
||||||
}
|
|
||||||
|
|
||||||
class MainWindowSplitter : public QMainWindow
|
|
||||||
{
|
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
|
||||||
explicit MainWindowSplitter(QWidget *parent = nullptr);
|
|
||||||
~MainWindowSplitter();
|
|
||||||
|
|
||||||
void setSplitterWidget(QtProjectWidgets *pWidgets);
|
|
||||||
|
|
||||||
void setModuleOpenOrClose();
|
|
||||||
|
|
||||||
MainWindowCurve* getMainWindowCurve();
|
|
||||||
|
|
||||||
private:
|
|
||||||
Ui::MainWindowSplitter *ui;
|
|
||||||
MainWindowCurve *m_mainWindowCurve = NULL;
|
|
||||||
QSplitter* m_pVSplitter = NULL;
|
|
||||||
QToolBar* m_PluginToolBar = NULL;
|
|
||||||
|
|
||||||
public slots:
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public:
|
|
||||||
|
|
||||||
QtProjectWidgets *m_leftWidgets = NULL; //左侧工程区
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // MainWindowSplitter_H
|
|
||||||
|
|
@ -1,22 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<ui version="4.0">
|
|
||||||
<class>MainWindowSplitter</class>
|
|
||||||
<widget class="QMainWindow" name="MainWindowSplitter">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>0</x>
|
|
||||||
<y>0</y>
|
|
||||||
<width>800</width>
|
|
||||||
<height>600</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="windowTitle">
|
|
||||||
<string>MainWindow</string>
|
|
||||||
</property>
|
|
||||||
<widget class="QWidget" name="centralwidget">
|
|
||||||
<layout class="QGridLayout" name="gridLayout"/>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
<resources/>
|
|
||||||
<connections/>
|
|
||||||
</ui>
|
|
||||||
Loading…
Reference in New Issue
Block a user