refs #289, settings for simulator

This commit is contained in:
Klaus Basan
2014-07-09 19:57:12 +02:00
parent cd88c79f7c
commit 76cbb5348c
4 changed files with 103 additions and 16 deletions

View File

@@ -21,14 +21,39 @@ namespace BlackMisc
return rp;
}
/*
* Wrong cmd message
*/
BlackMisc::CStatusMessage CSettingUtilities::wrongCommandMessage(const QString &command)
{
QString msg = "wrong command";
if (!command.isEmpty())
{
msg.append(": ").append(command);
}
BlackMisc::CStatusMessage rc(BlackMisc::CStatusMessage::TypeValidation,
BlackMisc::CStatusMessage::SeverityError, msg);
return rc;
}
/*
* Wrong path name messages
*/
CStatusMessageList CSettingUtilities::wrongPathMessages(const QString &path)
{
BlackMisc::CStatusMessageList rps;
rps.push_back(CSettingUtilities::wrongPathMessage(path));
return rps;
BlackMisc::CStatusMessageList wrongPath;
wrongPath.push_back(CSettingUtilities::wrongPathMessage(path));
return wrongPath;
}
/*
* Wrong command message
*/
CStatusMessageList CSettingUtilities::wrongCommandMessages(const QString &command)
{
BlackMisc::CStatusMessageList wrongCmds;
wrongCmds.push_back(CSettingUtilities::wrongCommandMessage(command));
return wrongCmds;
}
/*

View File

@@ -63,6 +63,12 @@ namespace BlackMisc
//! Wrong path messages
static BlackMisc::CStatusMessageList wrongPathMessages(const QString &path = "");
//! Wrong command message
static BlackMisc::CStatusMessage wrongCommandMessage(const QString &command);
//! Wrong command messages
static BlackMisc::CStatusMessageList wrongCommandMessages(const QString &command);
//! Value not changed message
static BlackMisc::CStatusMessage valueNotChangedMessage(const QString &valueName);