home · contact · privacy
In client, fixed bug hiding first entry in keybinding list drawings.
authorChristian Heller <c.heller@plomlompom.de>
Tue, 18 Mar 2014 04:55:38 +0000 (05:55 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Tue, 18 Mar 2014 04:55:38 +0000 (05:55 +0100)
src/client/draw_wins.c

index 04927db9af9d076f3ad092feb284074a7af1fe02..590d8c53cd49aa90afbc531c499fd05033a7d851 100644 (file)
@@ -309,7 +309,7 @@ static void draw_titled_keybinding_list(char * title, struct Win * win,
 {
     uint8_t state = 0;
     uint16_t kb_n = 0;
-    for (; (0 == state || kb_n < kbdb->n_of_kbs); kb_n++)
+    while (0 == state || kb_n < kbdb->n_of_kbs)
     {
         if (0 == state)
         {
@@ -321,6 +321,7 @@ static void draw_titled_keybinding_list(char * title, struct Win * win,
         char * kb_line = get_kb_line(&kbdb->kbs[kb_n], win->linebreak);
         add_line(win, kb_line, 0, offset, (last * kbdb->n_of_kbs == kb_n + 1));
         free(kb_line);
+        kb_n++;
     }
     if (2 == state)
     {