Remove unused i_enabled member from the playlist struct
authorRafaël Carré <funman@videolan.org>
Wed, 16 Apr 2008 22:31:17 +0000 (00:31 +0200)
committerRafaël Carré <funman@videolan.org>
Wed, 16 Apr 2008 22:31:17 +0000 (00:31 +0200)
include/vlc_playlist.h
modules/gui/qt4/menus.cpp
modules/gui/wince/interface.cpp
modules/gui/wince/iteminfo.cpp
modules/gui/wxwidgets/interface.cpp
src/playlist/item.c

index ce21567..acddcf4 100644 (file)
@@ -170,8 +170,6 @@ struct playlist_t
     } ** pp_sds;
     int                   i_sds;   /**< Number of service discovery modules */
 
-    int                   i_enabled; /**< How many items are enabled ? */
-
     playlist_item_array_t items; /**< Arrays of items */
     playlist_item_array_t all_items; /**< Array of items and nodes */
 
index 0f83f9f..577accf 100644 (file)
@@ -508,7 +508,7 @@ void QVLCMenu::PopupMenuControlEntries( QMenu *menu,
             addMIMStaticEntry( p_intf, menu, qtr( "Play" ), "",
                     ":/pixmaps/play_16px.png", SLOT( togglePlayPause() ) );
     }
-    else if( THEPL->items.i_size && THEPL->i_enabled )
+    else if( THEPL->items.i_size )
         addMIMStaticEntry( p_intf, menu, qtr( "Play" ), "",
                 ":/pixmaps/play_16px.png", SLOT( togglePlayPause() ) );
 
index 37cef1f..25f8795 100644 (file)
@@ -638,7 +638,7 @@ void Interface::OnPlayStream( void )
         vlc_object_find( p_intf, VLC_OBJECT_PLAYLIST, FIND_ANYWHERE );
     if( p_playlist == NULL ) return;
 
-    if( p_playlist->i_size && p_playlist->i_enabled )
+    if( p_playlist->i_size )
     {
         vlc_value_t state;
 
index 26a056e..bfcd5a9 100644 (file)
@@ -274,11 +274,6 @@ void ItemInfoDialog::OnOk()
     if( p_playlist != NULL )
     {
         b_state = SendMessage( enabled_checkbox, BM_GETCHECK, 0, 0 );
-        if( b_old_enabled == false && (b_state & BST_CHECKED) )
-            p_playlist->i_enabled ++;
-        else if( b_old_enabled == true && (b_state & BST_UNCHECKED) )
-            p_playlist->i_enabled --;
-
         vlc_object_release( p_playlist );
     }
 
index a4bd81a..256cf2a 100644 (file)
@@ -1080,7 +1080,7 @@ void Interface::PlayStream()
                                        FIND_ANYWHERE );
     if( p_playlist == NULL ) return;
 
-    if( !playlist_IsEmpty(p_playlist) && p_playlist->i_enabled )
+    if( !playlist_IsEmpty(p_playlist) )
     {
         vlc_value_t state;
 
index 8899ed5..0abf61b 100644 (file)
@@ -808,7 +808,6 @@ static void AddItem( playlist_t *p_playlist, playlist_item_t *p_item,
 {
     ARRAY_APPEND(p_playlist->items, p_item);
     ARRAY_APPEND(p_playlist->all_items, p_item);
-    p_playlist->i_enabled ++;
 
     if( i_pos == PLAYLIST_END )
         playlist_NodeAppend( p_playlist, p_item, p_node );