[vlc-devel] commit: Qt: interaction, add accelerators to the buttons. ( Jean-Baptiste Kempf )

git version control git at videolan.org
Sat Jan 17 13:27:55 CET 2009


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Sat Jan 17 13:25:52 2009 +0100| [8bcd3c6ffa2947edcb0baab48c1d357c36c9808e] | committer: Jean-Baptiste Kempf 

Qt: interaction, add accelerators to the buttons.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=8bcd3c6ffa2947edcb0baab48c1d357c36c9808e
---

 modules/gui/qt4/dialogs/interaction.cpp |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/modules/gui/qt4/dialogs/interaction.cpp b/modules/gui/qt4/dialogs/interaction.cpp
index 3eed13d..65b3863 100644
--- a/modules/gui/qt4/dialogs/interaction.cpp
+++ b/modules/gui/qt4/dialogs/interaction.cpp
@@ -78,15 +78,15 @@ InteractionDialog::InteractionDialog( intf_thread_t *_p_intf,
         cancelBox.setText( qfu( p_dialog->psz_description ) );
 
         if( p_dialog->psz_default_button )
-            cancelBox.addButton( qfu( p_dialog->psz_default_button ),
+            cancelBox.addButton( "&" + qfu( p_dialog->psz_default_button ),
                                  QMessageBox::AcceptRole );
 
         if( p_dialog->psz_alternate_button )
-            cancelBox.addButton( qfu( p_dialog->psz_alternate_button ),
+            cancelBox.addButton( "&" + qfu( p_dialog->psz_alternate_button ),
                                  QMessageBox::RejectRole );
 
         if( p_dialog->psz_other_button )
-            cancelBox.addButton( qfu( p_dialog->psz_other_button ),
+            cancelBox.addButton( "&" + qfu( p_dialog->psz_other_button ),
                                  QMessageBox::ActionRole );
 
         i_ret = cancelBox.exec();
@@ -164,19 +164,19 @@ InteractionDialog::InteractionDialog( intf_thread_t *_p_intf,
         {
             defaultButton = new QPushButton;
             defaultButton->setFocus();
-            defaultButton->setText( qfu( p_dialog->psz_default_button ) );
+            defaultButton->setText( "&" + qfu( p_dialog->psz_default_button ) );
             buttonBox->addButton( defaultButton, QDialogButtonBox::AcceptRole );
         }
         if( p_dialog->psz_alternate_button )
         {
             altButton = new QPushButton;
-            altButton->setText( qfu( p_dialog->psz_alternate_button ) );
+            altButton->setText( "&" + qfu( p_dialog->psz_alternate_button ) );
             buttonBox->addButton( altButton, QDialogButtonBox::RejectRole );
         }
         if( p_dialog->psz_other_button )
         {
             otherButton = new QPushButton;
-            otherButton->setText( qfu( p_dialog->psz_other_button ) );
+            otherButton->setText( "&" + qfu( p_dialog->psz_other_button ) );
             buttonBox->addButton( otherButton, QDialogButtonBox::ActionRole );
         }
         layout->addWidget( buttonBox );




More information about the vlc-devel mailing list