diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/term.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/term.c b/src/term.c index 451d608842d..553cc1b6084 100644 --- a/src/term.c +++ b/src/term.c | |||
| @@ -2893,7 +2893,7 @@ tty_menu_calc_size (tty_menu *menu, int *width, int *height) | |||
| 2893 | { | 2893 | { |
| 2894 | int i, h2, w2, maxsubwidth, maxheight; | 2894 | int i, h2, w2, maxsubwidth, maxheight; |
| 2895 | 2895 | ||
| 2896 | maxsubwidth = 0; | 2896 | maxsubwidth = menu->width; |
| 2897 | maxheight = menu->count; | 2897 | maxheight = menu->count; |
| 2898 | for (i = 0; i < menu->count; i++) | 2898 | for (i = 0; i < menu->count; i++) |
| 2899 | { | 2899 | { |
| @@ -2904,7 +2904,7 @@ tty_menu_calc_size (tty_menu *menu, int *width, int *height) | |||
| 2904 | if (i + h2 > maxheight) maxheight = i + h2; | 2904 | if (i + h2 > maxheight) maxheight = i + h2; |
| 2905 | } | 2905 | } |
| 2906 | } | 2906 | } |
| 2907 | *width = menu->width + maxsubwidth; | 2907 | *width = maxsubwidth; |
| 2908 | *height = maxheight; | 2908 | *height = maxheight; |
| 2909 | } | 2909 | } |
| 2910 | 2910 | ||