Improve the error message when autoload scripts fail to load

Remove a reference to errors "above" as the message appears both above
and below the actual errors.

Shorten the message a bit to reduce the chance of it getting truncated
by wx.

Fix the name of the button in the automation manager dialog.

Originally committed to SVN as r6500.
This commit is contained in:
Thomas Goyne 2012-02-22 20:47:24 +00:00
parent b59b3c56fc
commit 74fcf68fe2
1 changed files with 6 additions and 2 deletions

View File

@ -439,8 +439,12 @@ namespace Automation4 {
more = dir.GetNext(&fn); more = dir.GetNext(&fn);
} }
} }
if (error_count > 0) {
wxLogWarning("One or more scripts placed in the Automation autoload directory failed to load\nPlease review the errors above, correct them and use the Reload Autoload dir button in Automation Manager to attempt loading the scripts again."); if (error_count == 1) {
wxLogWarning("A script in the Automation autoload directory failed to load.\nPlease review the errors, fix them and use the Rescan Autoload Dir button in Automation Manager to load the scripts again.");
}
else if (error_count > 1) {
wxLogWarning("Multiple scripts in the Automation autoload directory failed to load.\nPlease review the errors, fix them and use the Rescan Autoload Dir button in Automation Manager to load the scripts again.");
} }
ScriptsChanged(); ScriptsChanged();