import java.util.List;
import jexer.TAction;
+import jexer.TCommand;
+import jexer.TKeypress;
import jexer.TList;
import jexer.TRadioGroup;
import jexer.TTreeItem;
import jexer.TWindow;
import be.nikiroo.fanfix.data.MetaData;
-public class TuiReaderMainWindow extends TWindow {
+class TuiReaderMainWindow extends TWindow {
private TList list;
private List<MetaData> listKeys;
private List<String> listItems;
/**
* Constructor.
*
- * @param parent
- * the main application
- * @param flags
- * bitmask of MODAL, CENTERED, or RESIZABLE
+ * @param reader
+ * the reader and main application
+ * @param stories
+ * the stories to display
*/
public TuiReaderMainWindow(TuiReaderApplication reader,
List<MetaData> stories) {
// Construct a demo window. X and Y don't matter because it will be
// centered on screen.
- super(reader, "Demo Window", 0, 0, 60, 18, CENTERED | RESIZABLE
+ super(reader, "Library", 0, 0, 60, 18, CENTERED | RESIZABLE
| UNCLOSABLE);
this.reader = reader;
}
});
+ // TODO: add the current "type" or filter
+ statusBar = newStatusBar("Library");
+ statusBar.addShortcutKeypress(TKeypress.kbF10, TCommand.cmExit, "Exit");
+
if (false) {
addLabel("Label (1,1)", 1, 1);
addButton("&Button (35,1)", 35, 1, new TAction() {