Set teh current selection to row 0

This commit is contained in:
dfighter1985 2014-07-30 11:14:41 +02:00
parent 99683c6569
commit 4a69a4f8b2
2 changed files with 8 additions and 0 deletions

View file

@ -749,6 +749,13 @@ void TileEditorMainWindow::onTileBankLoaded()
m_ui->tileBankTexturePathPB->setText( "..." );
else
m_ui->tileBankTexturePathPB->setText( path );
QModelIndex idx = m_tileModel->index( 0, 0 );
if( idx.isValid() )
m_ui->tileSetLV->setCurrentIndex( idx );
if( m_ui->landLW->count() > 0 )
m_ui->landLW->setCurrentRow( 0 );
}
TileModel* TileEditorMainWindow::createTileModel()

View file

@ -168,5 +168,6 @@ bool TileBankLoader::load( const char *filename, TileModel *model, QList< Land >
model->setTexturePath( p->bank.getAbsPath().c_str() );
return false;
}