diff options
Diffstat (limited to 'desktop-widgets/locationinformation.cpp')
-rw-r--r-- | desktop-widgets/locationinformation.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/desktop-widgets/locationinformation.cpp b/desktop-widgets/locationinformation.cpp index a57c6fb30..5872089a4 100644 --- a/desktop-widgets/locationinformation.cpp +++ b/desktop-widgets/locationinformation.cpp @@ -371,7 +371,7 @@ DiveLocationLineEdit::DiveLocationLineEdit(QWidget *parent) : QLineEdit(parent), view->setModel(proxy); view->setModelColumn(LocationInformationModel::NAME); - view->setItemDelegate(new LocationFilterDelegate()); + view->setItemDelegate(&delegate); view->setEditTriggers(QAbstractItemView::NoEditTriggers); view->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff); view->setSelectionBehavior(QAbstractItemView::SelectRows); @@ -570,6 +570,7 @@ void DiveLocationLineEdit::setCurrentDiveSite(struct dive *d) location_t currentLocation = d ? dive_get_gps_location(d) : location_t{0, 0}; proxy->setCurrentLocation(currentLocation); + delegate.setCurrentLocation(currentLocation); } void DiveLocationLineEdit::showPopup() |