mirror of
https://github.com/hneemann/Digital.git
synced 2025-09-27 23:18:02 -04:00
error message is always on top
This commit is contained in:
parent
b454445b14
commit
b05ba93ae0
@ -89,9 +89,15 @@ public class ErrorMessage implements Runnable {
|
|||||||
* @return this for call chaining
|
* @return this for call chaining
|
||||||
*/
|
*/
|
||||||
public ErrorMessage show(Component parent) {
|
public ErrorMessage show(Component parent) {
|
||||||
JOptionPane.showMessageDialog(parent,
|
JOptionPane optionPane = new JOptionPane(
|
||||||
new LineBreaker(120).toHTML().preserveContainedLineBreaks().breakLines(message.toString()),
|
new LineBreaker(120)
|
||||||
Lang.get("error"), JOptionPane.ERROR_MESSAGE);
|
.toHTML()
|
||||||
|
.preserveContainedLineBreaks()
|
||||||
|
.breakLines(message.toString()),
|
||||||
|
JOptionPane.ERROR_MESSAGE);
|
||||||
|
JDialog dialog = optionPane.createDialog(parent, Lang.get("error"));
|
||||||
|
dialog.setAlwaysOnTop(true);
|
||||||
|
dialog.setVisible(true);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user