static int map_source;
+ /* Tracker sort selection */
+ final static String trackerSortPreference = "TRACKER-SORT";
+
+ static int tracker_sort;
+
public static void init(Context context) {
if (backend != null)
return;
active_device_address = new DeviceAddress (address, name);
map_source = backend.getInt(mapSourcePreference, MAP_SOURCE_ONLINE);
+
+ tracker_sort = backend.getInt(trackerSortPreference, 0);
}
public static void set_active_device(DeviceAddress address) {
}
}
}
+
+
+ public static int tracker_sort() {
+ synchronized(backend) {
+ return tracker_sort;
+ }
+ }
+
+ public static void set_tracker_sort(int new_tracker_sort) {
+ synchronized(backend) {
+ if (tracker_sort != new_tracker_sort) {
+ tracker_sort = new_tracker_sort;
+ backend.putInt(trackerSortPreference, tracker_sort);
+ flush_preferences();
+ }
+ }
+ }
}