Commit f9ed4872 authored by Clément Stenac's avatar Clément Stenac

Cosmetics

parent 9f13f726
......@@ -48,7 +48,7 @@ StandardPLPanel::StandardPLPanel( QWidget *_parent, intf_thread_t *_p_intf,
view->setModel(model);
view->setIconSize( QSize(20,20) );
view->setAlternatingRowColors( true );
view->header()->resizeSection( 0, 300 );
view->header()->resizeSection( 0, 230 );
view->header()->setSortIndicatorShown( true );
view->header()->setClickable( true );
view->setSelectionMode( QAbstractItemView::ExtendedSelection );
......
......@@ -41,8 +41,11 @@ PlaylistDialog::PlaylistDialog( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
selector = new PLSelector( centralWidget(), p_intf, THEPL );
selector->setMaximumWidth( 140 );
playlist_item_t *p_root = playlist_GetPreferredNode( THEPL,
THEPL->p_local_category );
rightPanel = qobject_cast<PLPanel *>(new StandardPLPanel( centralWidget(),
p_intf, THEPL, THEPL->p_local_category ) );
p_intf, THEPL, p_root ) );
connect( selector, SIGNAL( activated( int ) ),
rightPanel, SLOT( setRoot( int ) ) );
......@@ -50,7 +53,7 @@ PlaylistDialog::PlaylistDialog( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
layout->addWidget( selector, 0 );
layout->addWidget( rightPanel, 10 );
centralWidget()->setLayout( layout );
readSettings( "playlist", QSize( 600,500 ) );
readSettings( "playlist", QSize( 600,700 ) );
}
PlaylistDialog::~PlaylistDialog()
......
......@@ -176,7 +176,6 @@ PLModel::~PLModel()
void PLModel::addCallbacks()
{
fprintf( stderr, "[%i] Adding callbacks\n", i_depth );
/* Some global changes happened -> Rebuild all */
var_AddCallback( p_playlist, "intf-change", PlaylistChanged, this );
/* We went to the next item */
......@@ -189,7 +188,6 @@ void PLModel::addCallbacks()
void PLModel::delCallbacks()
{
fprintf( stderr, "[%i] Rming callbacks\n", i_depth );
var_DelCallback( p_playlist, "item-change", ItemChanged, this );
var_DelCallback( p_playlist, "playlist-current", PlaylistNext, this );
var_DelCallback( p_playlist, "intf-change", PlaylistChanged, this );
......@@ -668,12 +666,10 @@ void PLModel::sort( int column, Qt::SortOrder order )
void PLModel::search( QString search_text )
{
/** \todo Fire the search with a small delay ? */
fprintf( stderr, "Searching\n" );
PL_LOCK;
playlist_item_t *p_root = playlist_ItemGetById( p_playlist,rootItem->i_id );
assert( p_root );
char *psz_name = search_text.toUtf8().data();
fprintf( stderr, "Searching %s\n", psz_name );
playlist_LiveSearchUpdate( p_playlist , p_root, psz_name );
PL_UNLOCK;
rebuild();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment