Update support code for Jexer
[jvcard.git] / src / be / nikiroo / jvcard / tui / windows / TuiContactWindow.java
... / ...
CommitLineData
1package be.nikiroo.jvcard.tui.windows;
2
3import jexer.TAction;
4import jexer.TKeypress;
5import jexer.TLabel;
6import jexer.TWindow;
7import be.nikiroo.jvcard.Contact;
8
9public class TuiContactWindow extends TuiBasicWindow {
10 public TuiContactWindow(final TuiBasicWindow parent, final Contact contact) {
11 super(parent, "Contact view");
12
13 addKeyBinding(TKeypress.kbQ, "Quit", new TAction() {
14 @Override
15 public void DO() {
16 parent.getApplication().closeWindow(TuiContactWindow.this);
17 }
18 });
19
20 addKeyBinding(TKeypress.kbR, "Raw view", new TAction() {
21 @Override
22 public void DO() {
23 @SuppressWarnings("unused")
24 TWindow w = new TuiRawContactWindow(TuiContactWindow.this,
25 contact);
26 }
27 });
28
29 @SuppressWarnings("unused")
30 TLabel l = new TLabel(this, "'r' to see raw view", 0, 0);
31 }
32}