use of com.googlecode.lanterna.gui2.dialogs.FileDialogBuilder in project security-lib by ncsa.
the class GUIDemo method componentTest.
public static void componentTest(Screen screen, TextGraphics textGraphics) {
final WindowBasedTextGUI textGUI = new MultiWindowTextGUI(screen);
final Window window = new MyWindow();
Panel contentPanel = new Panel(new GridLayout(2));
contentPanel.addComponent(new Button("open file", new Runnable() {
@Override
public void run() {
input = new FileDialogBuilder().setTitle("Open File").setDescription("Choose a file").setActionLabel("Open").build().showDialog(textGUI);
}
}));
window.setComponent(contentPanel);
textGUI.addWindowAndWait(window);
window.close();
}
Aggregations