diff options
-rw-r--r-- | mpd-notification.c | 19 | ||||
-rw-r--r-- | mpd-notification.h | 39 |
2 files changed, 40 insertions, 18 deletions
diff --git a/mpd-notification.c b/mpd-notification.c index b647a8c..00a9110 100644 --- a/mpd-notification.c +++ b/mpd-notification.c @@ -5,24 +5,7 @@ * of the GNU General Public License, incorporated herein by reference. */ -#include <mpd/client.h> - -#include <libnotify/notify.h> - -#include <stdio.h> -#include <unistd.h> -#include <stdlib.h> -#include <string.h> -#include <signal.h> -#include <getopt.h> -#include <regex.h> - -#include "config.h" -#include "version.h" - -#define PROGNAME "mpd-notification" - -#define NOTIFICATION_TIMEOUT 10000 +#include "mpd-notification.h" const static char optstring[] = "hH:m:p:v"; const static struct option options_long[] = { diff --git a/mpd-notification.h b/mpd-notification.h new file mode 100644 index 0000000..c618f68 --- /dev/null +++ b/mpd-notification.h @@ -0,0 +1,39 @@ +/* + * (C) 2014 by Christian Hesse <mail@eworm.de> + * + * This software may be used and distributed according to the terms + * of the GNU General Public License, incorporated herein by reference. + */ + +#ifndef MPD_NOTIFICATION_H +#define MPD_NOTIFICATION_H + +#include <mpd/client.h> + +#include <libnotify/notify.h> + +#include <stdio.h> +#include <unistd.h> +#include <stdlib.h> +#include <string.h> +#include <signal.h> +#include <getopt.h> +#include <regex.h> + +#include "config.h" +#include "version.h" + +#define PROGNAME "mpd-notification" + +#define NOTIFICATION_TIMEOUT 10000 + +/*** received_signal ***/ +void received_signal(int signal); + +/*** get_icon ***/ +char * get_icon(const char * music_dir, const char * uri); + +/*** main ***/ +int main(int argc, char ** argv); + +#endif /* MPD_NOTIFICATION_H */ |