Fixed issue #978. Don't show errors in History dialog.

Showing error messages instead of tool record can confuse a user. Additionally
it may create issues with a caret (feature insert after).
(grafted from 33a0a02a8ff5904b0226cbc1e94f36619db45212)

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2019-09-16 11:54:55 +03:00
parent 1bfd919e4a
commit 43b6125edd
2 changed files with 4 additions and 3 deletions

View File

@ -64,6 +64,7 @@
- Changing settings for move and rotate tools through property browser does not take in count previous change for label point and Show label option.
- Fix locking file after double save as.
- Key --ignoremargins still required margins.
- [#978] Don't show errors in History dialog.
# Version 0.6.1 October 23, 2018
- [#885] Regression. Broken support for multi size measurements.

View File

@ -218,7 +218,7 @@ QString DialogHistory::Record(const VToolRecord &tool)
if (domElem.isElement() == false)
{
qDebug()<<"Can't find element by id"<<Q_FUNC_INFO;
return tr("Can't create record.");
return QString();
}
try
{
@ -418,10 +418,10 @@ QString DialogHistory::Record(const VToolRecord &tool)
catch (const VExceptionBadId &e)
{
qDebug()<<e.ErrorMessage()<<Q_FUNC_INFO;
return tr("Can't create record.");
return QString();
}
qDebug()<<"Can't create history record for the tool.";
return tr("Can't create record.");
return QString();
}
QT_WARNING_POP