mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-17 20:50:34 +01:00
Change terminal strip editor class
Change parent class from QDialog to QWidget. Terminal strip editor is now embedded in TerminalStripEditorWindow.
This commit is contained in:
@@ -42,7 +42,6 @@
|
||||
#include "undocommand/rotateselectioncommand.h"
|
||||
#include "undocommand/rotatetextscommand.h"
|
||||
#include "diagram.h"
|
||||
#include "TerminalStrip/ui/terminalstripeditor.h"
|
||||
#include "TerminalStrip/ui/terminalstripeditorwindow.h"
|
||||
#include "ui/diagrameditorhandlersizewidget.h"
|
||||
|
||||
@@ -428,7 +427,7 @@ void QETDiagramEditor::setUpActions()
|
||||
|
||||
//Add a nomenclature item
|
||||
m_add_nomenclature = new QAction(QET::Icons::TableOfContent, tr("Ajouter une nomenclature"), this);
|
||||
connect(m_add_nomenclature, &QAction::triggered, [this]() {
|
||||
connect(m_add_nomenclature, &QAction::triggered, this, [=]() {
|
||||
if(this->currentDiagramView()) {
|
||||
QetGraphicsTableFactory::createAndAddNomenclature(this->currentDiagramView()->diagram());
|
||||
}
|
||||
@@ -436,21 +435,18 @@ void QETDiagramEditor::setUpActions()
|
||||
|
||||
//Add a summary item
|
||||
m_add_summary = new QAction(QET::Icons::TableOfContent, tr("Ajouter un sommaire"), this);
|
||||
connect(m_add_summary, &QAction::triggered, [this]() {
|
||||
connect(m_add_summary, &QAction::triggered, this, [=]() {
|
||||
if(this->currentDiagramView()) {
|
||||
QetGraphicsTableFactory::createAndAddSummary(this->currentDiagramView()->diagram());
|
||||
}
|
||||
});
|
||||
|
||||
m_terminal_strip_dialog = new QAction(QET::Icons::TerminalStrip, tr("Gestionnaire de borniers (DEV)"), this);
|
||||
connect(m_terminal_strip_dialog, &QAction::triggered, [this]()
|
||||
connect(m_terminal_strip_dialog, &QAction::triggered, this, [=]()
|
||||
{
|
||||
if (auto project = this->currentProject())
|
||||
{
|
||||
auto str = new TerminalStripEditor(project, this);
|
||||
str->show();
|
||||
|
||||
auto tsew = new TerminalStripEditorWindow(project, this);
|
||||
auto tsew {new TerminalStripEditorWindow{project, this}};
|
||||
tsew->show();
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user