Commit 8d5ee287 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt: provide a way to jump forward and backward programatically without going through hotkeys.

parent 87bbbc45
......@@ -791,6 +791,28 @@ void InputManager::setRate( int new_rate )
var_SetInteger( p_input, "rate", new_rate );
}
void InputManager::jumpFwd()
{
int i_interval = config_GetInt( p_input, "short-jump-size" );
if( i_interval > 0 )
{
vlc_value_t val;
val.i_time = (mtime_t)(i_interval) * 1000000L;
var_Set( p_input, "time-offset", val );
}
}
void InputManager::jumpBwd()
{
int i_interval = config_GetInt( p_input, "short-jump-size" );
if( i_interval > 0 )
{
vlc_value_t val;
val.i_time = -1 *(mtime_t)(i_interval) * 1000000L;
var_Set( p_input, "time-offset", val );
}
}
void InputManager::setAtoB()
{
if( !timeA )
......
......@@ -147,6 +147,9 @@ public slots:
void faster();
void normalRate();
void setRate( int );
/* Jumping */
void jumpFwd();
void jumpBwd();
/* Menus */
void sectionNext();
void sectionPrev();
......
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