diff --git a/src/libs/vtools/dialogs/tools/piece/dialoginsertnode.cpp b/src/libs/vtools/dialogs/tools/piece/dialoginsertnode.cpp index 35e4f8ad5..ca5328cd2 100644 --- a/src/libs/vtools/dialogs/tools/piece/dialoginsertnode.cpp +++ b/src/libs/vtools/dialogs/tools/piece/dialoginsertnode.cpp @@ -59,6 +59,12 @@ DialogInsertNode::~DialogInsertNode() void DialogInsertNode::SetPiecesList(const QVector &list) { FillComboBoxPiecesList(ui->comboBoxPiece, list); + + if (list.isEmpty()) + { + qWarning() << tr("The list of pieces is empty. Please, first create at least one piece for current pattern " + "piece."); + } } //--------------------------------------------------------------------------------------------------------------------- diff --git a/src/libs/vtools/dialogs/tools/piece/dialogpiecepath.cpp b/src/libs/vtools/dialogs/tools/piece/dialogpiecepath.cpp index 34c52a033..88d882ebf 100644 --- a/src/libs/vtools/dialogs/tools/piece/dialogpiecepath.cpp +++ b/src/libs/vtools/dialogs/tools/piece/dialogpiecepath.cpp @@ -1329,6 +1329,12 @@ QString DialogPiecePath::GetFormulaSAWidth() const void DialogPiecePath::SetPiecesList(const QVector &list) { FillComboBoxPiecesList(ui->comboBoxPiece, list); + + if (list.isEmpty()) + { + qWarning() << tr("The list of pieces is empty. Please, first create at least one piece for current pattern " + "piece."); + } } //--------------------------------------------------------------------------------------------------------------------- diff --git a/src/libs/vtools/dialogs/tools/piece/dialogpin.cpp b/src/libs/vtools/dialogs/tools/piece/dialogpin.cpp index 35c445ce5..f5f3ca625 100644 --- a/src/libs/vtools/dialogs/tools/piece/dialogpin.cpp +++ b/src/libs/vtools/dialogs/tools/piece/dialogpin.cpp @@ -116,6 +116,12 @@ void DialogPin::SetPointId(quint32 id) void DialogPin::SetPiecesList(const QVector &list) { FillComboBoxPiecesList(ui->comboBoxPiece, list); + + if (list.isEmpty()) + { + qWarning() << tr("The list of pieces is empty. Please, first create at least one piece for current pattern " + "piece."); + } } //--------------------------------------------------------------------------------------------------------------------- diff --git a/src/libs/vtools/dialogs/tools/piece/dialogplacelabel.cpp b/src/libs/vtools/dialogs/tools/piece/dialogplacelabel.cpp index f0bd3308c..318931283 100644 --- a/src/libs/vtools/dialogs/tools/piece/dialogplacelabel.cpp +++ b/src/libs/vtools/dialogs/tools/piece/dialogplacelabel.cpp @@ -234,6 +234,12 @@ void DialogPlaceLabel::SetPieceId(quint32 id) void DialogPlaceLabel::SetPiecesList(const QVector &list) { FillComboBoxPiecesList(ui->comboBoxPiece, list); + + if (list.isEmpty()) + { + qWarning() << tr("The list of pieces is empty. Please, first create at least one piece for current pattern " + "piece."); + } } //---------------------------------------------------------------------------------------------------------------------