]> git.tue.mpg.de Git - paraslash.git/commitdiff
Add new status items num_chunks and chunk_time.
authorAndre Noll <maan@systemlinux.org>
Sat, 8 Dec 2007 18:14:50 +0000 (19:14 +0100)
committerAndre Noll <maan@systemlinux.org>
Sat, 8 Dec 2007 18:14:50 +0000 (19:14 +0100)
aft.c
command.c
configure.ac
gui_theme.c

diff --git a/aft.c b/aft.c
index c54e6afb3e548f0fca8d16c73212fab741cc1f22..1d6a5070488ba3beb84a42f37dd0de2d3c0c3789 100644 (file)
--- a/aft.c
+++ b/aft.c
@@ -909,7 +909,9 @@ static int print_list_item(struct ls_data *d, struct ls_options *opts,
                "%s: %lu\n" /* seconds total */
                "%s: %s\n" /* last played time */
                "%s: %d\n" /* num_played */
-               "%s\n", /* tag info */
+               "%s" /* tag info */
+               "%s: %lu\n" /* chunk time */
+               "%s: %lu\n", /* num chunks */
                filename_lines,
                have_score? status_item_list[SI_SCORE] : "",
                        have_score? ": " : "",
@@ -927,7 +929,9 @@ static int print_list_item(struct ls_data *d, struct ls_options *opts,
                status_item_list[SI_SECONDS_TOTAL], afhi->seconds_total,
                status_item_list[SI_LAST_PLAYED], last_played_time,
                status_item_list[SI_NUM_PLAYED], afsi->num_played,
-               afhi->info_string
+               afhi->info_string,
+               status_item_list[SI_CHUNK_TIME], tv2ms(&afhi->chunk_tv),
+               status_item_list[SI_NUM_CHUNKS], afhi->chunks_total
        );
        if (opts->mode == LS_MODE_MBOX) {
                struct osl_object lyrics_def;
index 15fb7ab038e8f527f0ca1b7b5a9ccfd86aea1a84..aed9e6a0a34ab94ea6fce7b5708ac0b6e228efd2 100644 (file)
--- a/command.c
+++ b/command.c
@@ -108,7 +108,7 @@ static char *get_status(struct misc_meta_data *nmmd)
        flags = vss_get_status_flags(nmmd->vss_status_flags);
        if (nmmd->size) { /* parent currently has an audio file open */
                localtime_r(&nmmd->mtime, &mtime_tm);
-               strftime(mtime, 29, "%a %b %d %Y", &mtime_tm);
+               strftime(mtime, 29, "%b %d %Y", &mtime_tm);
        }
        gettimeofday(&now, NULL);
        ret = make_message(
index 73f6fdbff7b745cd598a3e912260587b0523a0bd..5b46c170185abd4143d36356b21c7f7bd95391b1 100644 (file)
@@ -559,7 +559,7 @@ status_flags format score audio_file_info taginfo1 taginfo2 afs_mode
 attributes_txt decoder_flags audiod_status play_time attributes_bitmap
 offset seconds_total stream_start current_time audiod_uptime image_id
 lyrics_id duration directory lyrics_name image_name path hash channels
-last_played"
+last_played num_chunks chunk_time"
 
 # $1: prefix, $2: items
 AC_DEFUN([make_enum_items], [$(
index e4cf39a2efe540a0d72c04922a6bbdbc72c5e659..8ece2e7f4a7345db97552fe4229a79b99a47e022 100644 (file)
@@ -200,60 +200,78 @@ static void init_theme_colorful_blackness(struct gui_theme *t)
        d[SI_SCORE].y = 17;
        d[SI_SCORE].len = 10;
 
-       d[SI_AUDIOD_STATUS].prefix = "audiod: ";
+       d[SI_AUDIOD_STATUS].prefix = "";
        d[SI_AUDIOD_STATUS].postfix = "";
        d[SI_AUDIOD_STATUS].fg = COLOR_MAGENTA;
        d[SI_AUDIOD_STATUS].bg = COLOR_BLACK;
-       d[SI_AUDIOD_STATUS].align = RIGHT;
+       d[SI_AUDIOD_STATUS].align = CENTER;
        d[SI_AUDIOD_STATUS].x = 0;
        d[SI_AUDIOD_STATUS].y = 27;
-       d[SI_AUDIOD_STATUS].len = 14;
+       d[SI_AUDIOD_STATUS].len = 5;
 
        d[SI_DECODER_FLAGS].prefix = "[";
        d[SI_DECODER_FLAGS].postfix = "]";
        d[SI_DECODER_FLAGS].fg = COLOR_MAGENTA;
        d[SI_DECODER_FLAGS].bg = COLOR_BLACK;
-       d[SI_DECODER_FLAGS].align = LEFT;
-       d[SI_DECODER_FLAGS].x = 15;
+       d[SI_DECODER_FLAGS].align = CENTER;
+       d[SI_DECODER_FLAGS].x = 5;
        d[SI_DECODER_FLAGS].y = 27;
        d[SI_DECODER_FLAGS].len = 10;
 
-       d[SI_MTIME].prefix = "Mtime: ";
+       d[SI_MTIME].prefix = "mod: ";
        d[SI_MTIME].postfix = "";
        d[SI_MTIME].fg = COLOR_MAGENTA;
        d[SI_MTIME].bg = COLOR_BLACK;
        d[SI_MTIME].align = CENTER;
-       d[SI_MTIME].x = 25;
+       d[SI_MTIME].x = 15;
        d[SI_MTIME].y = 27;
-       d[SI_MTIME].len = 29;
+       d[SI_MTIME].len = 22;
 
-       d[SI_FILE_SIZE].prefix = "Size: ";
+       d[SI_FILE_SIZE].prefix = "";
        d[SI_FILE_SIZE].postfix = "kb";
        d[SI_FILE_SIZE].fg = COLOR_MAGENTA;
        d[SI_FILE_SIZE].bg = COLOR_BLACK;
        d[SI_FILE_SIZE].align = CENTER;
-       d[SI_FILE_SIZE].x = 54;
+       d[SI_FILE_SIZE].x = 37;
        d[SI_FILE_SIZE].y = 27;
-       d[SI_FILE_SIZE].len = 17;
+       d[SI_FILE_SIZE].len = 10;
 
-       d[SI_CHANNELS].prefix = "ch: ";
-       d[SI_CHANNELS].postfix = "";
+       d[SI_CHANNELS].prefix = "";
+       d[SI_CHANNELS].postfix = "ch";
        d[SI_CHANNELS].fg = COLOR_MAGENTA;
        d[SI_CHANNELS].bg = COLOR_BLACK;
-       d[SI_CHANNELS].align = LEFT;
-       d[SI_CHANNELS].x = 71;
+       d[SI_CHANNELS].align = CENTER;
+       d[SI_CHANNELS].x = 47;
        d[SI_CHANNELS].y = 27;
-       d[SI_CHANNELS].len = 8;
+       d[SI_CHANNELS].len = 5;
 
        d[SI_LAST_PLAYED].prefix = "lp: ";
        d[SI_LAST_PLAYED].postfix = "";
        d[SI_LAST_PLAYED].fg = COLOR_MAGENTA;
        d[SI_LAST_PLAYED].bg = COLOR_BLACK;
        d[SI_LAST_PLAYED].align = CENTER;
-       d[SI_LAST_PLAYED].x = 79;
+       d[SI_LAST_PLAYED].x = 52;
        d[SI_LAST_PLAYED].y = 27;
        d[SI_LAST_PLAYED].len = 21;
 
+       d[SI_NUM_CHUNKS].prefix = "";
+       d[SI_NUM_CHUNKS].postfix = "x";
+       d[SI_NUM_CHUNKS].fg = COLOR_MAGENTA;
+       d[SI_NUM_CHUNKS].bg = COLOR_BLACK;
+       d[SI_NUM_CHUNKS].align = RIGHT;
+       d[SI_NUM_CHUNKS].x = 73;
+       d[SI_NUM_CHUNKS].y = 27;
+       d[SI_NUM_CHUNKS].len = 12;
+
+       d[SI_CHUNK_TIME].prefix = " ";
+       d[SI_CHUNK_TIME].postfix = "ms";
+       d[SI_CHUNK_TIME].fg = COLOR_MAGENTA;
+       d[SI_CHUNK_TIME].bg = COLOR_BLACK;
+       d[SI_CHUNK_TIME].align = LEFT;
+       d[SI_CHUNK_TIME].x = 85;
+       d[SI_CHUNK_TIME].y = 27;
+       d[SI_CHUNK_TIME].len = 15;
+
        d[SI_AUDIO_FILE_INFO].prefix = "";
        d[SI_AUDIO_FILE_INFO].postfix = "";
        d[SI_AUDIO_FILE_INFO].fg = COLOR_GREEN;