aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <cbaines8@gmail.com>2012-01-31 14:19:38 +0000
committerChristopher Baines <cbaines8@gmail.com>2012-01-31 14:19:38 +0000
commit2f581670f84f5c7d9b43d8657f7d6f5ab7e5e98e (patch)
treed9b98728d269884ab65de89fb56d85d05da93381
parent86a67409307ff384ee0ef07d677045c6e82e52e8 (diff)
downloadsouthamptonuniversitymap-2f581670f84f5c7d9b43d8657f7d6f5ab7e5e98e.tar
southamptonuniversitymap-2f581670f84f5c7d9b43d8657f7d6f5ab7e5e98e.tar.gz
Fixed some FindActivity stuff.
-rw-r--r--res/layout/find.xml2
-rw-r--r--src/net/cbaines/suma/FindActivity.java7
2 files changed, 6 insertions, 3 deletions
diff --git a/res/layout/find.xml b/res/layout/find.xml
index 62a3000..6b19c67 100644
--- a/res/layout/find.xml
+++ b/res/layout/find.xml
@@ -10,7 +10,7 @@
android:id="@+id/searchBar"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
- android:inputType="text" />
+ android:inputType="textNoSuggestions" />
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
diff --git a/src/net/cbaines/suma/FindActivity.java b/src/net/cbaines/suma/FindActivity.java
index f0a16ac..154cd64 100644
--- a/src/net/cbaines/suma/FindActivity.java
+++ b/src/net/cbaines/suma/FindActivity.java
@@ -25,7 +25,6 @@ import java.util.Collections;
import java.util.Iterator;
import java.util.List;
-
import org.osmdroid.util.GeoPoint;
import android.content.Context;
@@ -278,7 +277,11 @@ public class FindActivity extends OrmLiteBaseActivity<DatabaseHelper> implements
}
// Register the listener with the Location Manager to receive location updates
locationManager.requestLocationUpdates(LocationManager.GPS_PROVIDER, 10000, 10, this);
- locationManager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 10000, 10, this);
+ try {
+ locationManager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 10000, 10, this);
+ } catch (Exception e) {
+ // Ignore anything that goes wrong here...
+ }
// SotonBusData.getTimetable("SN120128");