mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-31 23:23:23 +00:00
Select an index if no index is selected
Defaults to first row. Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
cc6967b53c
commit
d95856d3b2
1 changed files with 3 additions and 1 deletions
|
@ -522,6 +522,9 @@ void DiveLocationLineEdit::fixPopupPosition()
|
|||
}
|
||||
|
||||
view->setGeometry(pos.x(), pos.y(), w, h);
|
||||
if(!view->currentIndex().isValid()) {
|
||||
view->setCurrentIndex(view->model()->index(0,1));
|
||||
}
|
||||
}
|
||||
|
||||
void DiveLocationLineEdit::showPopup()
|
||||
|
@ -530,7 +533,6 @@ void DiveLocationLineEdit::showPopup()
|
|||
if (!view->isVisible()) {
|
||||
setTemporaryDiveSiteName(text());
|
||||
proxy->invalidate();
|
||||
view->setCurrentIndex(view->model()->index(0,1));
|
||||
view->show();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue