Skip to content

Commit

Permalink
command: add dummy get implementation for tv-channel property
Browse files Browse the repository at this point in the history
A small cosmetic change with the effect that pressing 'k' shows
"unavailable" instead of "error" (even if no  TV code is active).
  • Loading branch information
wm4 authored and olifre committed Feb 28, 2015
1 parent 3ed51d2 commit ba8364a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions player/command.c
Original file line number Diff line number Diff line change
Expand Up @@ -2855,6 +2855,8 @@ static int mp_property_tv_channel(void *ctx, struct m_property *prop,
return M_PROPERTY_OK;
case M_PROPERTY_SET:
return prop_stream_ctrl(ctx, STREAM_CTRL_TV_SET_CHAN, *(char **)arg);
case M_PROPERTY_GET:
return prop_stream_ctrl(ctx, STREAM_CTRL_TV_GET_CHAN, arg);
case M_PROPERTY_SWITCH: {
struct m_property_switch_arg *sa = arg;
int dir = sa->inc >= 0 ? 1 : -1;
Expand Down
1 change: 1 addition & 0 deletions stream/stream.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ enum stream_ctrl {
STREAM_CTRL_TV_SET_NORM,
STREAM_CTRL_TV_STEP_NORM,
STREAM_CTRL_TV_SET_CHAN,
STREAM_CTRL_TV_GET_CHAN,
STREAM_CTRL_TV_STEP_CHAN,
STREAM_CTRL_TV_LAST_CHAN,
STREAM_CTRL_DVB_SET_CHANNEL,
Expand Down

0 comments on commit ba8364a

Please sign in to comment.