Commit dbc2edac authored by Laurent Aimar's avatar Laurent Aimar

Simplify up/down subtitle hotkey.

parent 6650cb88
...@@ -783,21 +783,15 @@ static int PutAction( intf_thread_t *p_intf, int i_action ) ...@@ -783,21 +783,15 @@ static int PutAction( intf_thread_t *p_intf, int i_action )
_( "Subtitle delay %i ms" ), _( "Subtitle delay %i ms" ),
(int)(i_delay/1000) ); (int)(i_delay/1000) );
} }
else if( i_action == ACTIONID_SUBPOS_DOWN ) else if( i_action == ACTIONID_SUBPOS_DOWN ||
i_action == ACTIONID_SUBPOS_UP )
{ {
int i_pos = var_GetInteger( p_input, "sub-margin" ); int i_pos;
--i_pos; if( i_action == ACTIONID_SUBPOS_DOWN )
var_SetInteger( p_input, "sub-margin", i_pos ); i_pos = var_DecInteger( p_input, "sub-margin" );
ClearChannels( p_intf, p_vout ); else
DisplayMessage( p_vout, SPU_DEFAULT_CHANNEL, i_pos = var_IncInteger( p_input, "sub-margin" );
_( "Subtitle position %i px" ),
(int)(i_pos) );
}
else if( i_action == ACTIONID_SUBPOS_UP )
{
int i_pos = var_GetInteger( p_input, "sub-margin" );
++i_pos;
var_SetInteger( p_input, "sub-margin", i_pos );
ClearChannels( p_intf, p_vout ); ClearChannels( p_intf, p_vout );
DisplayMessage( p_vout, SPU_DEFAULT_CHANNEL, DisplayMessage( p_vout, SPU_DEFAULT_CHANNEL,
_( "Subtitle position %i px" ), _( "Subtitle position %i px" ),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment