]> git.sesse.net Git - vlc/commitdiff
Qt: display an "empty" action instead of an empty menu
authorJean-Baptiste Kempf <jb@videolan.org>
Mon, 10 Oct 2011 09:56:10 +0000 (11:56 +0200)
committerJean-Baptiste Kempf <jb@videolan.org>
Mon, 10 Oct 2011 10:00:59 +0000 (12:00 +0200)
modules/gui/qt4/util/qmenuview.cpp

index d40981219988425e49601e89a148768096f54c4a..8ec2d3ed60b0de1994315e54c77025288ef64101 100644 (file)
@@ -67,6 +67,9 @@ void QMenuView::rebuild()
 
     /* Rebuild from root */
     build( QModelIndex() );
+
+    if( isEmpty() )
+        addAction( qtr( "Empty" ) )->setDisabled( true );
 }
 
 /* */