*/
public void actionErrorWhiteList() {
Object selected = listAllErrors.getSelectedItem();
if ((selected instanceof CheckError) &&
(Utilities.isDesktopSupported())) {
EnumWikipedia wiki = getWikipedia();
CheckError error = (CheckError) selected;
if (error.getAlgorithm().getWhiteListPageName() != null) {
Utilities.browseURL(wiki, error.getAlgorithm().getWhiteListPageName(), true);
} else {
DecimalFormat format = new DecimalFormat("000");
String parameter =
"error_" +
format.format(error.getErrorNumber()) +
"_whitelistpage_" +
wiki.getSettings().getCodeCheckWiki();
String translationPage = wiki.getConfiguration().getString(
WPCConfigurationString.CW_TRANSLATION_PAGE);
Utilities.displayInformationMessage(getParentComponent(), GT._(
"There''s no whitelist defined for this error type.\n" +
"If you want to define a whitelist, you need to add:\n" +
" {0} = <page name> END\n" +
"to the translation page ({1}) on \"{2}\"",
new Object[] { parameter, translationPage, wiki.toString()
}));
}
}
}