void (ActionEvent e) { if (safeToConvert == EncodingUtil.Magic8.NO_WAY) { EncodingUtil.FailReason error = EncodingUtil.checkCanConvert(virtualFile); int res = Messages.showDialog( XmlStringUtil.wrapInHtml( IdeBundle.message("encoding.do.not.convert.message", charset.displayName()) + "<br><br>" + (error == null ? IdeBundle.message("encoding.unsupported.characters.message", charset.displayName()) : EncodingUtil.reasonToString(error, virtualFile))), IdeBundle.message("incompatible.encoding.dialog.title", charset.displayName()), new String[]{IdeBundle.message("button.convert.anyway"), CommonBundle.getCancelButtonText()}, 1, AllIcons.General.WarningDialog); if (res != 0) { doCancelAction(); return; } } close(CONVERT_EXIT_CODE); }