From: Max Kellermann Date: Thu, 2 Oct 2008 13:30:47 +0000 (+0200) Subject: screen_browser: unexport command implementations X-Git-Tag: v0.12_alpha1~115 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=9526f180e6f55654c99bd8d66c71612a32b0fb4e;p=ncmpc.git screen_browser: unexport command implementations When we created created browser_cmd(), several functions of the screen_browser API weren't used by other sources anymore. We can now unexport them. --- diff --git a/src/screen_browser.c b/src/screen_browser.c index 694987f..b8a1b1e 100644 --- a/src/screen_browser.c +++ b/src/screen_browser.c @@ -255,7 +255,7 @@ browser_get_selected(const struct screen_browser *browser) return filelist_get(browser->filelist, browser->lw->selected); } -int +static int browser_handle_enter(struct screen_browser *browser, mpdclient_t *c) { struct filelist_entry *entry = browser_get_selected(browser); @@ -380,7 +380,7 @@ browser_select_entry(mpdclient_t *c, filelist_entry_t *entry, return 0; } -int +static int browser_handle_select(struct screen_browser *browser, mpdclient_t *c) { struct filelist_entry *entry = browser_get_selected(browser); @@ -391,7 +391,7 @@ browser_handle_select(struct screen_browser *browser, mpdclient_t *c) return browser_select_entry(c, entry, TRUE); } -int +static int browser_handle_add(struct screen_browser *browser, mpdclient_t *c) { struct filelist_entry *entry = browser_get_selected(browser); @@ -402,7 +402,7 @@ browser_handle_add(struct screen_browser *browser, mpdclient_t *c) return browser_select_entry(c, entry, FALSE); } -void +static void browser_handle_select_all(struct screen_browser *browser, mpdclient_t *c) { guint i; @@ -419,7 +419,7 @@ browser_handle_select_all(struct screen_browser *browser, mpdclient_t *c) } #ifdef HAVE_GETMOUSE -int +static int browser_handle_mouse_event(struct screen_browser *browser, mpdclient_t *c) { int row; @@ -492,9 +492,11 @@ browser_cmd(struct screen_browser *browser, struct screen *screen, browser->filelist); return true; +#ifdef HAVE_GETMOUSE case CMD_MOUSE_EVENT: browser_handle_mouse_event(browser, c); return true; +#endif #ifdef ENABLE_LYRICS_SCREEN case CMD_SCREEN_LYRICS: diff --git a/src/screen_browser.h b/src/screen_browser.h index eb11336..2b825c0 100644 --- a/src/screen_browser.h +++ b/src/screen_browser.h @@ -47,28 +47,10 @@ browser_playlist_changed(struct screen_browser *browser, mpdclient_t *c, const char *browser_lw_callback(unsigned index, int *highlight, void *filelist); -int -browser_handle_select(struct screen_browser *browser, mpdclient_t *c); - -int -browser_handle_add(struct screen_browser *browser, mpdclient_t *c); - -void -browser_handle_select_all(struct screen_browser *browser, mpdclient_t *c); - int browser_change_directory(struct screen_browser *browser, mpdclient_t *c, filelist_entry_t *entry, const char *new_path); -int -browser_handle_enter(struct screen_browser *browser, mpdclient_t *c); - -#ifdef HAVE_GETMOUSE -int browser_handle_mouse_event(struct screen_browser *browser, mpdclient_t *c); -#else -#define browser_handle_mouse_event(browser, c) (0) -#endif - bool browser_cmd(struct screen_browser *browser, struct screen *screen, struct mpdclient *c, command_t cmd);