Added back button, removed list selection from location list view when
[situare] / src / ui / locationsearchpanel.cpp
index 63449a0..533da07 100644 (file)
@@ -107,9 +107,9 @@ LocationSearchPanel::LocationSearchPanel(QWidget *parent)
     connect(searchLocationButton, SIGNAL(clicked()),
             this, SIGNAL(requestSearchLocation()));
 
-    m_clearLocationListButton = new ImageButton(":/res/images/clear_btn.png",
-                                                ":/res/images/clear_btn_s.png",
-                                                ":/res/images/clear_btn_d.png", this);
+    m_clearLocationListButton = new ImageButton(":/res/images/back_btn.png",
+                                                ":/res/images/back_btn_s.png",
+                                                ":/res/images/back_btn_d.png", this);
     m_clearLocationListButton->setDisabled(true);
 
     connect(m_clearLocationListButton, SIGNAL(clicked()),
@@ -190,16 +190,6 @@ void LocationSearchPanel::populateLocationListView(const QList<Location> &locati
         m_locationListView->addListItem(QString::number(i), item);
     }
 
-    const int FIRST_LOCATION_ITEM_INDEX = 0;
-    const int ONE_LOCATION_ITEM = 1;
-
-    if (locations.size() == ONE_LOCATION_ITEM) {
-        ListItem *item = m_locationListView->listItemAt(FIRST_LOCATION_ITEM_INDEX);
-
-        if (item)
-            m_locationListView->setSelectedItem(item);
-    }
-
     m_locationListView->scrollToTop();
 }