[vlc-devel] commit: qt4: fix typo + cosmetics (Jakob Leben )
git version control
git at videolan.org
Sun Aug 23 16:44:44 CEST 2009
vlc | branch: master | Jakob Leben <jleben at videolan.org> | Sun Aug 23 16:43:19 2009 +0200| [b1cb50d46af18f7913ee1d395228e24d91f58151] | committer: Jakob Leben
qt4: fix typo + cosmetics
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=b1cb50d46af18f7913ee1d395228e24d91f58151
---
.../gui/qt4/components/playlist/playlist_model.cpp | 9 ++++-----
.../gui/qt4/components/playlist/playlist_model.hpp | 2 +-
.../gui/qt4/components/playlist/standardpanel.cpp | 2 +-
3 files changed, 6 insertions(+), 7 deletions(-)
diff --git a/modules/gui/qt4/components/playlist/playlist_model.cpp b/modules/gui/qt4/components/playlist/playlist_model.cpp
index 77b8dd1..52cfc76 100644
--- a/modules/gui/qt4/components/playlist/playlist_model.cpp
+++ b/modules/gui/qt4/components/playlist/playlist_model.cpp
@@ -649,7 +649,7 @@ meta_col must be contained in shown_flags!
*/
int PLModel::columnFromMeta( int meta_col, int shown_flags ) const
{
- assert( meta & shown_flags );
+ assert( meta_col & shown_flags );
int meta = 1;
int index = -1;
@@ -1044,15 +1044,14 @@ void PLModel::popup( QModelIndex & index, QPoint &point, QModelIndexList list )
menu->popup( point );
}
-void PLModel::viewchanged( int meta )
+void PLModel::toggleColumnShown( int meta )
{
assert( meta );
- int _meta = meta;
if( rootItem )
{
if( i_showflags & meta )
- /* Removing columns */
{
+ /* Removing columns */
int index = columnFromMeta( meta, i_showflags );
beginRemoveColumns( QModelIndex(), index, index );
@@ -1062,10 +1061,10 @@ void PLModel::viewchanged( int meta )
}
else
{
+ /* Adding columns */
int sf = i_showflags;
sf |= meta;
int index = columnFromMeta( meta, sf );
- /* Adding columns */
beginInsertColumns( QModelIndex(), index, index );
i_showflags = sf;
getSettings()->setValue( "qt-pl-showflags", i_showflags );
diff --git a/modules/gui/qt4/components/playlist/playlist_model.hpp b/modules/gui/qt4/components/playlist/playlist_model.hpp
index 3160e57..c8d5da0 100644
--- a/modules/gui/qt4/components/playlist/playlist_model.hpp
+++ b/modules/gui/qt4/components/playlist/playlist_model.hpp
@@ -201,7 +201,7 @@ private slots:
void popupAddNode();
void popupSortAsc();
void popupSortDesc();
- void viewchanged( int );
+ void toggleColumnShown( int meta_column );
void processInputItemUpdate( input_item_t *);
void processInputItemUpdate( input_thread_t* p_input );
};
diff --git a/modules/gui/qt4/components/playlist/standardpanel.cpp b/modules/gui/qt4/components/playlist/standardpanel.cpp
index a12158f..18d6886 100644
--- a/modules/gui/qt4/components/playlist/standardpanel.cpp
+++ b/modules/gui/qt4/components/playlist/standardpanel.cpp
@@ -323,7 +323,7 @@ void StandardPLPanel::popupSelectColumn( QPoint pos )
CONNECT( option, triggered(), ContextUpdateMapper, map() );
}
- CONNECT( ContextUpdateMapper, mapped( int ), model, viewchanged( int ) );
+ CONNECT( ContextUpdateMapper, mapped( int ), model, toggleColumnShown( int ) );
selectColMenu.exec( QCursor::pos() );
}
More information about the vlc-devel
mailing list