mirror of https://github.com/apache/lucene.git
Add a clear button for log content
This commit is contained in:
parent
3ae59a9809
commit
753edd83c3
|
@ -87,6 +87,16 @@ public final class LogsPanelProvider {
|
||||||
});
|
});
|
||||||
header.add(copyBtn);
|
header.add(copyBtn);
|
||||||
|
|
||||||
|
JButton clearBtn =
|
||||||
|
new JButton(
|
||||||
|
MessageUtils.getLocalizedMessage("button.clear"));
|
||||||
|
clearBtn.setMargin(new Insets(3, 3, 3, 3));
|
||||||
|
clearBtn.addActionListener(
|
||||||
|
e -> {
|
||||||
|
logTextArea.setText(null);
|
||||||
|
});
|
||||||
|
header.add(clearBtn);
|
||||||
|
|
||||||
panel.add(header, BorderLayout.PAGE_START);
|
panel.add(header, BorderLayout.PAGE_START);
|
||||||
panel.add(new JScrollPane(logTextArea), BorderLayout.CENTER);
|
panel.add(new JScrollPane(logTextArea), BorderLayout.CENTER);
|
||||||
return panel;
|
return panel;
|
||||||
|
|
Loading…
Reference in New Issue