[vlc-devel] commit: Qt Fix profile edition and saving. Close #2477 ( Jean-Baptiste Kempf )
git version control
git at videolan.org
Sat Feb 7 00:51:12 CET 2009
vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Sat Feb 7 00:50:07 2009 +0100| [0ea61050862d41d60e430fa66d613b8650b40150] | committer: Jean-Baptiste Kempf
Qt Fix profile edition and saving. Close #2477
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=0ea61050862d41d60e430fa66d613b8650b40150
---
.../gui/qt4/components/sout/profile_selector.cpp | 3 ++-
.../gui/qt4/components/sout/profile_selector.hpp | 2 +-
modules/gui/qt4/util/qvlcframe.hpp | 12 +++++-------
3 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/modules/gui/qt4/components/sout/profile_selector.cpp b/modules/gui/qt4/components/sout/profile_selector.cpp
index b52d17f..4893c17 100644
--- a/modules/gui/qt4/components/sout/profile_selector.cpp
+++ b/modules/gui/qt4/components/sout/profile_selector.cpp
@@ -58,6 +58,7 @@ inline void VLCProfileSelector::fillProfilesCombo()
for( int i = 0; i < i_size; i++ )
{
settings.setArrayIndex( i );
+ if( settings.value( "Profile-Name" ).toString().isEmpty() ) continue;
profileBox->addItem( settings.value( "Profile-Name" ).toString(),
settings.value( "Profile-Value" ) );
}
@@ -204,7 +205,7 @@ VLCProfileEditor::VLCProfileEditor( QString qs_name, QString value,
inline void VLCProfileEditor::registerCodecs()
{
-
+
#define ADD_VCODEC( name, fourcc ) ui.vCodecBox->addItem( name, QVariant( fourcc ) );
ADD_VCODEC( "MPEG-1", "mp1v" )
ADD_VCODEC( "MPEG-2", "mp2v" )
diff --git a/modules/gui/qt4/components/sout/profile_selector.hpp b/modules/gui/qt4/components/sout/profile_selector.hpp
index 6a70db5..e8b4364 100644
--- a/modules/gui/qt4/components/sout/profile_selector.hpp
+++ b/modules/gui/qt4/components/sout/profile_selector.hpp
@@ -70,7 +70,7 @@ public:
private:
void registerCodecs();
void fillProfile( QString qs );
-protected:
+protected slots:
virtual void close();
private slots:
void setVTranscodeOptions( bool );
diff --git a/modules/gui/qt4/util/qvlcframe.hpp b/modules/gui/qt4/util/qvlcframe.hpp
index b48c3ca..059497f 100644
--- a/modules/gui/qt4/util/qvlcframe.hpp
+++ b/modules/gui/qt4/util/qvlcframe.hpp
@@ -155,13 +155,13 @@ protected:
{
if( keyEvent->key() == Qt::Key_Escape )
{
- cancel();
+ this->cancel();
}
else if( keyEvent->key() == Qt::Key_Return
|| keyEvent->key() == Qt::Key_Enter )
{
- close();
- }
+ this->close();
+ }
}
};
@@ -193,14 +193,12 @@ protected:
{
if( keyEvent->key() == Qt::Key_Escape )
{
- msg_Dbg( p_intf, "Escp Key pressed" );
- cancel();
+ this->cancel();
}
else if( keyEvent->key() == Qt::Key_Return
|| keyEvent->key() == Qt::Key_Enter )
{
- msg_Dbg( p_intf, "Enter Key pressed" );
- close();
+ this->close();
}
}
};
More information about the vlc-devel
mailing list