1
mirror of https://code.videolan.org/videolan/vlc synced 2024-10-03 01:31:53 +02:00

Qt: add the popup menu in the main interface

This commit is contained in:
Jean-Philippe Andre 2009-02-19 21:51:46 +08:00
parent 7410f0f5c0
commit 10962a57ff
2 changed files with 11 additions and 0 deletions

View File

@ -256,6 +256,11 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
/* Playlist */
if( b_visible ) togglePlaylist();
/* Enable the popup menu in the MI */
setContextMenuPolicy( Qt::CustomContextMenu );
CONNECT( this, customContextMenuRequested( const QPoint& ),
this, popupMenu() );
/* Final sizing and showing */
setMinimumWidth( __MAX( controls->sizeHint().width(),
menuBar()->sizeHint().width() ) );
@ -647,6 +652,11 @@ void MainInterface::toggleFSC()
QApplication::postEvent( fullscreenControls, eShow );
}
void MainInterface::popupMenu()
{
QVLCMenu::PopupMenu( p_intf, true );
}
void MainInterface::debug()
{
#ifndef NDEBUG

View File

@ -159,6 +159,7 @@ public slots:
void toggleAdvanced();
void toggleFullScreen();
void toggleFSC();
void popupMenu();
/* Manage the Video Functions from the vout threads */
void releaseVideoSlot( void );