Removed an unused parameter in previous_visible().
authorFrancois Fleuret <francois@fleuret.org>
Thu, 17 Jun 2010 20:37:48 +0000 (22:37 +0200)
committerFrancois Fleuret <francois@fleuret.org>
Thu, 17 Jun 2010 20:37:48 +0000 (22:37 +0200)
selector.c

index 95d8968..8f2296b 100644 (file)
@@ -428,8 +428,7 @@ void kill_after_cursor(char *buffer, int *position) {
 
 /*********************************************************************/
 
-int previous_visible(int current_line, int nb_lines, char **lines,
-                     matcher_t *matcher) {
+int previous_visible(int current_line, char **lines, matcher_t *matcher) {
   int line = current_line - 1;
   while(line >= 0 && !match(lines[line], matcher)) line--;
   return line;
@@ -502,8 +501,7 @@ void update_screen(int *current_focus_line, int *displayed_focus_line,
       new_focus_line = next_visible(*current_focus_line, nb_lines, lines,
                                     &matcher);
       if(new_focus_line < 0) {
-        new_focus_line = previous_visible(*current_focus_line, nb_lines, lines,
-                                          &matcher);
+        new_focus_line = previous_visible(*current_focus_line, lines, &matcher);
       }
     }
 
@@ -522,7 +520,7 @@ void update_screen(int *current_focus_line, int *displayed_focus_line,
       } else {
         /* We want to go up, let's find the first visible line above */
         for(m = 0; l >= 0 && m < -motion; m++) {
-          l = previous_visible(l, nb_lines, lines, &matcher);
+          l = previous_visible(l, lines, &matcher);
           if(l >= 0) {
             new_focus_line = l;
           }