diff options
author | lostd <lostd@2f30.org> | 2014-10-07 15:36:29 +0000 |
---|---|---|
committer | lostd <> | 2014-10-07 15:36:29 +0000 |
commit | 10d2d18cb244d76862b508d7dffa65c6a5147040 (patch) | |
tree | 14c6c63edeab534a66859875d276c6cc0c535a7e /noice.c | |
parent | 88fd8fcf8b325cb5c5e6cb0a5553537039a10690 (diff) | |
download | noice-10d2d18cb244d76862b508d7dffa65c6a5147040.tar.gz |
Reorder configuration stuff
Diffstat (limited to 'noice.c')
-rw-r--r-- | noice.c | 39 |
1 files changed, 21 insertions, 18 deletions
@@ -26,6 +26,27 @@ #define MIN(x, y) ((x) < (y) ? (x) : (y)) #define ISODD(x) ((x) & 1) +struct assoc { + char *ext; /* Extension */ + char *bin; /* Program */ +}; + +/* Configuration */ +struct assoc assocs[] = { + { ".avi", "mplayer" }, + { ".mp4", "mplayer" }, + { ".mkv", "mplayer" }, + { ".mp3", "mplayer" }, + { ".ogg", "mplayer" }, + { ".srt", "less" }, + { ".txt", "less" }, + { "README", "less" }, +}; + +#define CWD "cwd: " +#define CURSR " > " +#define EMPTY " " + /* * Layout: * .--------- @@ -49,20 +70,6 @@ struct entry { char name[MAXNAMLEN + 1]; }; -struct assoc { - char *ext; /* Extension */ - char *bin; /* Program */ -} assocs[] = { - { ".avi", "mplayer" }, - { ".mp4", "mplayer" }, - { ".mkv", "mplayer" }, - { ".mp3", "mplayer" }, - { ".ogg", "mplayer" }, - { ".srt", "less" }, - { ".txt", "less" }, - { "README", "less" }, -}; - char * openwith(char *file) { @@ -266,10 +273,6 @@ redraw: DPRINTF_D(cur); DPRINTF_S(path); -#define CWD "cwd: " -#define CURSR " > " -#define EMPTY " " - /* No text wrapping in cwd line */ cwd = malloc(COLS * sizeof(char)); strncpy(cwd, path, COLS); |