1
0
mirror of https://github.com/mitb-archive/filebot synced 2024-12-24 16:58:51 -05:00

Better error messages (hopefully)

@see https://www.filebot.net/forums/viewtopic.php?f=10&t=4241
This commit is contained in:
Reinhard Pointner 2016-10-18 02:41:11 +08:00
parent d39675c033
commit 7b1146f168

View File

@ -438,16 +438,13 @@ class SubtitleAutoMatchDialog extends JDialog {
if (value == null) { if (value == null) {
setText("Cancel selection"); setText("Cancel selection");
setIcon(ResourceManager.getIcon("dialog.cancel")); setIcon(ResourceManager.getIcon("dialog.cancel"));
setToolTipText(null);
} else { } else {
if (subtitleBean.getError() == null) { if (subtitleBean.getError() == null) {
setText(subtitleBean.getText()); setText(subtitleBean.getText());
setIcon(subtitleBean.getIcon()); setIcon(subtitleBean.getIcon());
setToolTipText(null);
} else { } else {
setText(String.format("%s (%s)", subtitleBean.getError().getMessage(), subtitleBean.getText())); setText(String.format("%s (%s)", subtitleBean.getError(), subtitleBean.getText()));
setIcon(ResourceManager.getIcon("status.warning")); setIcon(ResourceManager.getIcon("status.warning"));
setToolTipText(subtitleBean.getError().toString());
} }
if (!isSelected) { if (!isSelected) {