setWindowRole( "vlc-main" );
setWindowIcon( QApplication::windowIcon() );
setWindowOpacity( var_InheritFloat( p_intf, "qt-opacity" ) );
+#ifdef Q_WS_MAC
+ setAttribute( Qt::WA_MacBrushedMetal );
+#endif
/* Is video in embedded in the UI or not */
b_videoEmbedded = var_InheritBool( p_intf, "embedded-video" );
settings->setValue( "pl-dock-status", b_plDocked );
/* Save playlist state */
if( playlistWidget )
- {
- settings->setValue( "playlist-visible",
- isPlDocked() ?
- playlistVisible :
- playlistWidget->isVisible() /* FIXME */ );
- }
+ settings->setValue( "playlist-visible", playlistVisible );
settings->setValue( "adv-controls",
getControlsVisibilityStatus() & CONTROLS_ADVANCED );
CONNECT( THEMIM->getIM(), seekRequested( float ),
timeLabel, setDisplayPosition( float ) );
+
+ /* This shouldn't be necessary, but for somehow reason, the statusBarr
+ starts at height of 20px and when a text is shown it needs more space.
+ But, as the QMainWindow policy doesn't allow statusBar to change QMW's
+ geometry, we need to force a height. If you have a better idea, please
+ tell me -- jb
+ */
+ statusBarr->setFixedHeight( statusBarr->sizeHint().height() + 2 );
}
/**********************************************************************
{
case QSystemTrayIcon::Trigger:
case QSystemTrayIcon::DoubleClick:
+#ifdef Q_WS_MAC
+ QVLCMenu::updateSystrayMenu( this, p_intf );
+#else
toggleUpdateSystrayMenu();
+#endif
break;
case QSystemTrayIcon::MiddleClick:
sysTray->showMessage( qtr( "VLC media player" ),
{
if( url.isValid() )
{
- char* psz_uri = make_URI( qtu( url.toString() ) );
+ char* psz_uri = make_URI( qtu( url.toString() ), NULL );
playlist_Add( THEPL, psz_uri, NULL,
PLAYLIST_APPEND | (first ? PLAYLIST_GO: PLAYLIST_PREPARSE),
PLAYLIST_END, true, pl_Unlocked );
if( !mimeData->hasUrls() && mimeData->hasText() &&
QUrl(mimeData->text()).isValid() )
{
- char *psz_uri = make_URI( qtu( mimeData->text() ) );
+ char *psz_uri = make_URI( qtu( mimeData->text() ), NULL );
playlist_Add( THEPL, psz_uri, NULL,
PLAYLIST_APPEND | (first ? PLAYLIST_GO: PLAYLIST_PREPARSE),
PLAYLIST_END, true, pl_Unlocked );