diff --git a/src/screen_file.c b/src/screen_file.c
index 124108bb770a55f482764ba59d860f302b7063f5..2af1655d3b3eca3e89c425c831ce3d7182a77865 100644 (file)
--- a/src/screen_file.c
+++ b/src/screen_file.c
/* ncmpc (Ncurses MPD Client)
- * (c) 2004-2010 The Music Player Daemon Project
+ * (c) 2004-2017 The Music Player Daemon Project
* Project homepage: http://musicpd.org
*
* This program is free software; you can redistribute it and/or modify
static struct screen_browser browser;
static char *current_path;
-static void
-screen_file_paint(void);
-
-static void
-screen_file_repaint(void)
-{
- screen_file_paint();
- wrefresh(browser.lw->w);
-}
-
static void
screen_file_load_list(struct mpdclient *c, struct filelist *filelist)
{
const struct mpd_playlist *playlist = mpd_entity_get_playlist(entity);
char *str = utf8_to_locale(g_basename(mpd_playlist_get_path(playlist)));
- char *buf = g_strdup_printf(_("Delete playlist %s [%s/%s] ? "), str, YES, NO);
+ char *buf = g_strdup_printf(_("Delete playlist %s?"), str);
g_free(str);
bool delete = screen_get_yesno(buf, false);
g_free(buf);
}
static void
-screen_file_init(WINDOW *w, int cols, int rows)
+screen_file_init(WINDOW *w, unsigned cols, unsigned rows)
{
current_path = g_strdup("");
}
static void
-screen_file_resize(int cols, int rows)
+screen_file_resize(unsigned cols, unsigned rows)
{
list_window_resize(browser.lw, cols, rows);
}
#endif
)) {
screen_browser_sync_highlights(browser.filelist, &c->playlist);
- screen_file_repaint();
+ screen_file_paint();
}
}
switch(cmd) {
case CMD_PLAY:
if (screen_file_handle_enter(c)) {
- screen_file_repaint();
+ screen_file_paint();
return true;
}
case CMD_GO_ROOT_DIRECTORY:
change_directory(c, "");
- screen_file_repaint();
+ screen_file_paint();
return true;
case CMD_GO_PARENT_DIRECTORY:
change_to_parent(c);
- screen_file_repaint();
+ screen_file_paint();
return true;
case CMD_LOCATE:
case CMD_SCREEN_UPDATE:
screen_file_reload(c);
screen_browser_sync_highlights(browser.filelist, &c->playlist);
- screen_file_repaint();
+ screen_file_paint();
return false;
default:
if (browser_cmd(&browser, c, cmd)) {
if (screen_is_visible(&screen_browse))
- screen_file_repaint();
+ screen_file_paint();
return true;
}
switch(cmd) {
case CMD_DELETE:
handle_delete(c);
- screen_file_repaint();
+ screen_file_paint();
break;
case CMD_SAVE_PLAYLIST: