Commit fac5ea40 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt4 - Fix the GotoTime handler. Closes #377.

parent 60f4db26
...@@ -49,6 +49,7 @@ GotoTimeDialog::GotoTimeDialog( intf_thread_t *_p_intf) : QVLCFrame( _p_intf ) ...@@ -49,6 +49,7 @@ GotoTimeDialog::GotoTimeDialog( intf_thread_t *_p_intf) : QVLCFrame( _p_intf )
QPushButton *cancelButton = new QPushButton( qtr( "&Cancel" ) ); QPushButton *cancelButton = new QPushButton( qtr( "&Cancel" ) );
QDialogButtonBox *buttonBox = new QDialogButtonBox; QDialogButtonBox *buttonBox = new QDialogButtonBox;
gotoButton->setDefault( true );
buttonBox->addButton( gotoButton, QDialogButtonBox::AcceptRole ); buttonBox->addButton( gotoButton, QDialogButtonBox::AcceptRole );
buttonBox->addButton( cancelButton, QDialogButtonBox::RejectRole ); buttonBox->addButton( cancelButton, QDialogButtonBox::RejectRole );
...@@ -99,12 +100,11 @@ void GotoTimeDialog::cancel() ...@@ -99,12 +100,11 @@ void GotoTimeDialog::cancel()
void GotoTimeDialog::close() void GotoTimeDialog::close()
{ {
vlc_value_t val;
if ( THEMIM->getIM()->hasInput() ) if ( THEMIM->getIM()->hasInput() )
{ {
val.i_time = QTime( 0, 0, 0 ).msecsTo( timeEdit->time() ); int64_t i_time = (int64_t)
var_Set( THEMIM->getInput(), "time", val ); ( QTime( 0, 0, 0 ).msecsTo( timeEdit->time() ) ) * 1000;
var_SetTime( THEMIM->getInput(), "time", i_time );
} }
this->toggleVisible(); this->toggleVisible();
} }
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