]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
gui: Remove change_theme().
authorAndre Noll <maan@systemlinux.org>
Tue, 7 Jan 2014 22:08:00 +0000 (22:08 +0000)
committerAndre Noll <maan@systemlinux.org>
Sun, 4 May 2014 13:48:54 +0000 (15:48 +0200)
It's silly to have a function for this.

gui.c
gui_theme.c

diff --git a/gui.c b/gui.c
index 25e852dee462d3d394723bd26935f8cfbf6ecaa7..01af3227ffda5227d8243c9c8ec5a51ea79b62c9 100644 (file)
--- a/gui.c
+++ b/gui.c
@@ -1411,27 +1411,18 @@ static void com_refresh(void)
        init_curses();
 }
 
        init_curses();
 }
 
-static void change_theme(int next)
-{
-       if (next)
-               theme_next(&theme);
-       else
-               theme_prev(&theme);
-       com_refresh();
-       PARA_NOTICE_LOG("new theme: %s\n", theme.name);
-}
-
 static void com_next_theme(void)
 {
 static void com_next_theme(void)
 {
-       change_theme(1);
+       theme_next(&theme);
+       com_refresh();
 }
 
 static void com_prev_theme(void)
 {
 }
 
 static void com_prev_theme(void)
 {
-       change_theme(0);
+       theme_prev(&theme);
+       com_refresh();
 }
 
 }
 
-
 static void handle_command(int c)
 {
        int i;
 static void handle_command(int c)
 {
        int i;
index 3963d35267e33307fc68867513a08c66ccfb591f..3c9886d18a2a2a3cbae88a74f79b052391b64672 100644 (file)
@@ -381,6 +381,7 @@ static void set_theme(int num, struct gui_theme *t)
        t->name = themes[num].name;
        themes[num].init(t);
        current_theme_num = num;
        t->name = themes[num].name;
        themes[num].init(t);
        current_theme_num = num;
+       PARA_NOTICE_LOG("theme: %s\n", t->name);
 }
 
 void theme_init(const char *name, struct gui_theme *t)
 }
 
 void theme_init(const char *name, struct gui_theme *t)