emit inputIsRecordable( b_hasInput &&
var_GetBool( THEMIM->getInput(), "can-record" ) );
+
+ emit inputIsTrickPlayable( b_hasInput &&
+ var_GetBool( THEMIM->getInput(), "can-rewind" ) );
}
/* Generic button setup */
bool b_flat = options & WIDGET_FLAT;
bool b_big = options & WIDGET_BIG;
bool b_shiny = options & WIDGET_SHINY;
+ bool b_special = false;
QWidget *widget = NULL;
switch( button )
widget = telexFrame();
widget->hide();
break;
+ case VOLUME_SPECIAL:
+ b_special = true;
case VOLUME:
{
- SoundWidget *snd = new SoundWidget( this, p_intf, b_shiny );
+ SoundWidget *snd = new SoundWidget( this, p_intf, b_shiny, b_special );
widget = snd;
}
break;
setupButton( reverseButton );
CONNECT_MAP_SET( reverseButton, REVERSE_ACTION );
BUTTON_SET_BAR( reverseButton );
- ENABLE_ON_INPUT( reverseButton );
+ reverseButton->setCheckable( true );
+ /* You should, of COURSE change this to the correct event,
+ when/if we have one, that tells us if trickplay is possible . */
+ CONNECT( this, inputIsTrickPlayable( bool ), reverseButton, setVisible( bool ) );
+ reverseButton->setVisible( false );
widget = reverseButton;
}
break;
/**
* Telextext QFrame
**/
- TeletextController *telexFrame = new TeletextController;
+ QFrame *telexFrame = new QFrame;
QHBoxLayout *telexLayout = new QHBoxLayout( telexFrame );
telexLayout->setSpacing( 0 ); telexLayout->setMargin( 0 );
CONNECT( THEMIM->getIM(), teletextPossible( bool ),
/* On/Off button */
QToolButton *telexOn = new QToolButton;
- telexFrame->telexOn = telexOn;
setupButton( telexOn );
BUTTON_SET_BAR2( telexOn, tv, qtr( "Teletext Activation" ) );
+ telexOn->setEnabled( false );
+ telexOn->setCheckable( true );
+
telexLayout->addWidget( telexOn );
/* Teletext Activation and set */
CONNECT( telexOn, clicked( bool ),
THEMIM->getIM(), activateTeletext( bool ) );
- CONNECT( THEMIM->getIM(), teletextActivated( bool ),
- telexFrame, enableTeletextButtons( bool ) );
-
+ CONNECT( THEMIM->getIM(), teletextPossible( bool ),
+ telexOn, setEnabled( bool ) );
/* Transparency button */
QToolButton *telexTransparent = new QToolButton;
- telexFrame->telexTransparent = telexTransparent;
setupButton( telexTransparent );
BUTTON_SET_BAR2( telexTransparent, tvtelx,
qtr( "Toggle Transparency " ) );
/* Page setting */
- QSpinBox *telexPage = new QSpinBox;
- telexFrame->telexPage = telexPage;
+ QSpinBox *telexPage = new QSpinBox( telexFrame );
telexPage->setRange( 0, 999 );
telexPage->setValue( 100 );
telexPage->setAccelerated( true );
CONNECT( THEMIM->getIM(), newTelexPageSet( int ),
telexPage, setValue( int ) );
+ CONNECT( THEMIM->getIM(), teletextActivated( bool ), telexPage, setEnabled( bool ) );
+ CONNECT( THEMIM->getIM(), teletextActivated( bool ), telexTransparent, setEnabled( bool ) );
+ CONNECT( THEMIM->getIM(), teletextActivated( bool ), telexOn, setChecked( bool ) );
return telexFrame;
}
#undef CONNECT_MAP
adjustSize();
/* center down */
int number = QApplication::desktop()->screenNumber( p_intf->p_sys->p_mi );
- if( number != i_screennumber )
+ if( number != i_screennumber ||
+ screenRes != QApplication::desktop()->screenGeometry(number) )
{
+ screenRes = QApplication::desktop()->screenGeometry(number);
msg_Dbg( p_intf, "Calculation fullscreen controllers center");
/* screen has changed, calculate new position */
- QRect screenRes = QApplication::desktop()->screenGeometry(number);
QPoint pos = QPoint( screenRes.x() + (screenRes.width() / 2) - (width() / 2),
screenRes.y() + screenRes.height() - height());
move( pos );
/* Force fs hidding */
IMEvent *eHide = new IMEvent( FullscreenControlHide_Type, 0 );
- QApplication::postEvent( this, static_cast<QEvent *>(eHide) );
+ QApplication::postEvent( this, eHide );
}
vlc_mutex_unlock( &lock );
}
{
/* Show event */
IMEvent *eShow = new IMEvent( FullscreenControlShow_Type, 0 );
- QApplication::postEvent( this, static_cast<QEvent *>(eShow) );
+ QApplication::postEvent( this, eShow );
/* Plan hide event */
IMEvent *eHide = new IMEvent( FullscreenControlPlanHide_Type, 0 );
- QApplication::postEvent( this, static_cast<QEvent *>(eHide) );
+ QApplication::postEvent( this, eHide );
}
}