From 5499e11cdbb225b631a0f84f1b3a99965717306e Mon Sep 17 00:00:00 2001 From: dbv Date: Tue, 6 Dec 2016 17:11:03 +0300 Subject: [PATCH] Issue #1005: To improve user-friendship of error-messages for features and attributes Fix for crash when start Wire feature. --- src/ModuleBase/ModuleBase_WidgetAction.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/ModuleBase/ModuleBase_WidgetAction.h b/src/ModuleBase/ModuleBase_WidgetAction.h index 9003a91a4..f65e1d83a 100755 --- a/src/ModuleBase/ModuleBase_WidgetAction.h +++ b/src/ModuleBase/ModuleBase_WidgetAction.h @@ -38,7 +38,13 @@ Q_OBJECT /// \return Context for translation virtual std::string context() const { - return myFeature->getKind() + ":" + myActionID; + std::string aContext = myFeatureId; + if(!aContext.empty() && !myActionID.empty()) { + aContext += ":"; + } + aContext += myActionID; + + return aContext; } protected: -- 2.39.2