When program starts, it should display the main menu where there are
all options this program serves.
Signed-off-by: Vitezslav Samel <vitezslav(a)samel.cz>
---
src/iptraf.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/src/iptraf.c b/src/iptraf.c
index 13b650c..29ba055 100644
--- a/src/iptraf.c
+++ b/src/iptraf.c
@@ -169,9 +169,8 @@ void program_interface(struct OPTIONS *options, int opt, char
*optarg,
attrset(STATUSBARATTR);
mvprintw(LINES - 1, 1, PLATFORM);
- about();
- tx_initmenu(&menu, 13, 35, (LINES - 14) / 2, (COLS - 35) / 2, BOXATTR,
+ tx_initmenu(&menu, 15, 35, (LINES - 16) / 2, (COLS - 35) / 2, BOXATTR,
STDATTR, HIGHATTR, BARSTDATTR, BARHIGHATTR, DESCATTR);
tx_additem(&menu, " IP traffic ^m^onitor",
@@ -190,6 +189,8 @@ void program_interface(struct OPTIONS *options, int opt, char
*optarg,
tx_additem(&menu, NULL, NULL);
tx_additem(&menu, " C^o^nfigure...", "Set various program
options");
tx_additem(&menu, NULL, NULL);
+ tx_additem(&menu, " ^A^bout...", "Displays program info");
+ tx_additem(&menu, NULL, NULL);
tx_additem(&menu, " E^x^it", "Exits program");
endloop = 0;
@@ -261,6 +262,9 @@ void program_interface(struct OPTIONS *options, int opt, char
*optarg,
saveoptions(options);
break;
case 11:
+ about();
+ break;
+ case 13:
endloop = 1;
break;
}
--
1.7.8.4