Minor GUI fixes

FossilOrigin-Name: 2bf7d04d9971660eacc30c6e05bfa82c595bbf6c
This commit is contained in:
kostas
2012-05-12 08:29:59 +00:00
parent 6b470516fa
commit 747539b15c
3 changed files with 15 additions and 9 deletions

View File

@@ -947,6 +947,8 @@ void MainWindow::updateFileView()
ui->tableView->resizeColumnsToContents();
ui->tableView->horizontalHeader()->setMovable(true);
ui->tableView->resizeRowsToContents();
// Needed on OSX as the preset value from the GUI editor is not always reflected
ui->tableView->horizontalHeader()->setStretchLastSection(true);
}
//------------------------------------------------------------------------------
@@ -2100,11 +2102,15 @@ QString MainWindow::getFossilHttpAddress()
//------------------------------------------------------------------------------
void MainWindow::onTreeViewSelectionChanged(const QItemSelection &/*selected*/, const QItemSelection &/*deselected*/)
{
selectedDirs.clear();
QModelIndexList selection = ui->treeView->selectionModel()->selectedIndexes();
int num_selected = selection.count();
// Do not modify the selection if nothing is selected
if(num_selected==0)
return;
selectedDirs.clear();
for(int i=0; i<num_selected; ++i)
{
QModelIndex index = selection.at(i);