summaryrefslogtreecommitdiffstats
path: root/command.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-08-19 18:05:05 +0200
committerwm4 <wm4@nowhere>2012-09-07 16:06:36 +0200
commit330c90cbb8583ac41547bcd3d7259bc7b9e6a3b5 (patch)
treea2e58e54888fa6f64f5ee15adf52631f72255f48 /command.c
parent83f68f725d80b23f76c9a8cd8dbb8349b33c9779 (diff)
downloadmpv-330c90cbb8583ac41547bcd3d7259bc7b9e6a3b5.tar.bz2
mpv-330c90cbb8583ac41547bcd3d7259bc7b9e6a3b5.tar.xz
command: remove sub_log command
Not very useful, and introduced special cases. Just get rid of it, can be reintroduced if in a better way if someone misses this feature.
Diffstat (limited to 'command.c')
-rw-r--r--command.c46
1 files changed, 0 insertions, 46 deletions
diff --git a/command.c b/command.c
index 48606be43c..0e33ac3c64 100644
--- a/command.c
+++ b/command.c
@@ -185,48 +185,6 @@ static void update_global_sub_size(MPContext *mpctx)
}
}
-/**
- * \brief Log the currently displayed subtitle to a file
- *
- * Logs the current or last displayed subtitle together with filename
- * and time information to ~/.mplayer/subtitle_log
- *
- * Intended purpose is to allow convenient marking of bogus subtitles
- * which need to be fixed while watching the movie.
- */
-
-static void log_sub(struct MPContext *mpctx)
-{
- char *fname;
- FILE *f;
- int i;
- struct subtitle *vo_sub_last = mpctx->vo_sub_last;
-
- if (mpctx->subdata == NULL || vo_sub_last == NULL)
- return;
- fname = get_path("subtitle_log");
- f = fopen(fname, "a");
- if (!f)
- return;
- fprintf(f, "----------------------------------------------------------\n");
- if (mpctx->subdata->sub_uses_time) {
- fprintf(f,
- "N: %s S: %02ld:%02ld:%02ld.%02ld E: %02ld:%02ld:%02ld.%02ld\n",
- mpctx->filename, vo_sub_last->start / 360000,
- (vo_sub_last->start / 6000) % 60,
- (vo_sub_last->start / 100) % 60, vo_sub_last->start % 100,
- vo_sub_last->end / 360000, (vo_sub_last->end / 6000) % 60,
- (vo_sub_last->end / 100) % 60, vo_sub_last->end % 100);
- } else {
- fprintf(f, "N: %s S: %ld E: %ld\n", mpctx->filename,
- vo_sub_last->start, vo_sub_last->end);
- }
- for (i = 0; i < vo_sub_last->lines; i++)
- fprintf(f, "%s\n", vo_sub_last->text[i]);
- fclose(f);
-}
-
-
static int mp_property_generic_option(struct m_option *prop, int action,
void *arg, MPContext *mpctx)
{
@@ -2881,10 +2839,6 @@ void run_command(MPContext *mpctx, mp_cmd_t *cmd)
}
break;
- case MP_CMD_SUB_LOG:
- log_sub(mpctx);
- break;
-
case MP_CMD_OSD: {
int v = cmd->args[0].v.i;
int max = (opts->term_osd