]> git.deb.at Git - pkg/abook.git/blobdiff - ui.c
- make it compile with tcc
[pkg/abook.git] / ui.c
diff --git a/ui.c b/ui.c
index 27aa91f12f35edc1cc828c92188b1a83446d312b..bde07e4fde9e45288580e6bd00cea188160df046 100644 (file)
--- a/ui.c
+++ b/ui.c
@@ -63,7 +63,6 @@ static void
 init_windows()
 {
        top = newwin(LIST_TOP - 1, COLS, 0, 0);
-
        bottom = newwin(LINES - LIST_BOTTOM, COLS, LIST_BOTTOM, 0);
 }
 
@@ -112,7 +111,7 @@ resize_abook()
 static void
 win_changed(int i)
 {
-       if( can_resize )
+       if(can_resize)
                resize_abook();
        else
                should_resize = TRUE;
@@ -155,15 +154,15 @@ init_ui()
                return 1;
        }
 
-#ifdef SIGWINCH
-       signal(SIGWINCH, win_changed);
-#endif
-
        init_list();
        init_windows();
 
        ui_initialized = TRUE;
 
+#ifdef SIGWINCH
+       signal(SIGWINCH, win_changed);
+#endif
+
        return 0;
 }
 
@@ -198,7 +197,7 @@ void
 refresh_screen()
 {
 #ifdef SIGWINCH
-       if( should_resize ) {
+       if(should_resize) {
                resize_abook();
                return;
        }
@@ -284,7 +283,6 @@ statusline_ask_boolean(char *msg, int def)
        return ret;
 }
 
-
 void
 refresh_statusline()
 {
@@ -296,7 +294,6 @@ refresh_statusline()
        wrefresh(bottom);
 }
 
-
 char *
 ask_filename(char *prompt)
 {
@@ -347,8 +344,8 @@ display_help(int help)
 
        for(i = 0; tbl[i] != NULL; i++) {
                waddstr(helpw, tbl[i]);
-               if( ( !( (i+1) % (LINES-8) ) ) ||
-                       (tbl[i+1] == NULL) ) {
+               if( (!((i + 1) % (LINES - 8))) ||
+                       (tbl[i + 1] == NULL) ) {
                        refresh();
                        wrefresh(helpw);
                        refresh_statusline();
@@ -467,7 +464,6 @@ get_commands()
        }
 }
 
-
 void
 ui_remove_items()
 {