* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
+
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include "components/info_panels.hpp"
#include "components/interface_widgets.hpp"
+#include <assert.h>
+
#include <QTreeWidget>
-#include <QListView>
-#include <QPushButton>
#include <QHeaderView>
#include <QList>
#include <QStringList>
#include <QLineEdit>
#include <QLabel>
#include <QSpinBox>
-#include <QTabWidget>
/************************************************************************
* Single panels
line++;
/* ART_URL */
- art_cover = new CoverArtLabel( this, VLC_OBJECT( p_intf ) );
+ art_cover = new CoverArtLabel( this, p_intf );
metaLayout->addWidget( art_cover, line, 8, 4, 2, Qt::AlignRight );
/* Settings is unused */
b_inEditMode = false;
}
-MetaPanel::~MetaPanel(){}
-
/**
* Update all the MetaData and art on an "item-changed" event
**/
void MetaPanel::update( input_item_t *p_item )
{
+ if( !p_item )
+ {
+ clear();
+ return;
+ }
+
/* Don't update if you are in edit mode */
if( b_inEditMode ) return;
else p_input = p_item;
#undef UPDATE_META_INT
#undef UPDATE_META
- /* Update Art */
- art_cover->update( p_item );
}
/**
PL_LOCK;
p_playlist->p_private = &p_export;
- module_t *p_mod = module_need( p_playlist, "meta writer", NULL, 0 );
+ module_t *p_mod = module_need( p_playlist, "meta writer", NULL, false );
if( p_mod )
module_unneed( p_playlist, p_mod );
PL_UNLOCK;
language_text->clear();
nowplaying_text->clear();
publisher_text->clear();
- art_cover->update( NULL );
setEditMode( false );
+ emit uriSet( "" );
}
/**
**/
void ExtraMetaPanel::update( input_item_t *p_item )
{
+ if( !p_item )
+ {
+ clear();
+ return;
+ }
+
QStringList tempItem;
QList<QTreeWidgetItem *> items;
layout->addWidget(InfoTree, 1, 0 );
}
-InfoPanel::~InfoPanel()
-{
-}
-
/**
* Update the Codecs information on parent->update()
**/
void InfoPanel::update( input_item_t *p_item)
{
+ if( !p_item )
+ {
+ clear();
+ return;
+ }
+
InfoTree->clear();
QTreeWidgetItem *current_item = NULL;
QTreeWidgetItem *child_item = NULL;
"0", video, "" );
CREATE_AND_ADD_TO_CAT( vlost_frames_stat, qtr("Lost frames"),
"0", video, "" );
-// CREATE_AND_ADD_TO_CAT( vfps_stat, qtr("FPS"), "0", video, "" );
CREATE_AND_ADD_TO_CAT( send_stat, qtr("Sent packets"), "0", streaming, "" );
CREATE_AND_ADD_TO_CAT( send_bytes_stat, qtr("Sent bytes"),
layout->addWidget(StatsTree, 1, 0 );
}
-InputStatsPanel::~InputStatsPanel()
-{
-}
-
/**
* Update the Statistics
**/
void InputStatsPanel::update( input_item_t *p_item )
{
+ assert( p_item );
vlc_mutex_lock( &p_item->p_stats->lock );
#define UPDATE( widget, format, calc... ) \
UPDATE( vdecoded_stat, "%5i", p_item->p_stats->i_decoded_video );
UPDATE( vdisplayed_stat, "%5i", p_item->p_stats->i_displayed_pictures );
UPDATE( vlost_frames_stat, "%5i", p_item->p_stats->i_lost_pictures );
-/* UPDATE( vfps_stat, "%5f", p_item->p_stats->i_lost_pictures );
-input_Control( p_input_thread, INPUT_GET_VIDEO_FPS, &f_fps */
/* Sout */
UPDATE( send_stat, "%5i", p_item->p_stats->i_sent_packets );
void InputStatsPanel::clear()
{
}
+