Skip to content
Snippets Groups Projects
Commit 28ed06f2 authored by Peter Joseph De Jonckheere CESM2014's avatar Peter Joseph De Jonckheere CESM2014
Browse files

a

parent 97f6ff5e
No related branches found
No related tags found
No related merge requests found
...@@ -79,7 +79,10 @@ public class DataAnalysis { ...@@ -79,7 +79,10 @@ public class DataAnalysis {
List<Place> places = SaveFile.getPlaces(context); List<Place> places = SaveFile.getPlaces(context);
Place[] sortedPlaces = (Place[])(quicksort(places.toArray(), 0, places.size()-1)); Place[] sortedPlaces = (Place[])(quicksort(places.toArray(), 0, places.size()-1));
int popularType = getPopularElement(sortedPlaces); int popularType = getPopularElement(sortedPlaces);
SharedPreferences preferences = context.getSharedPreferences(context.getString(R.string.preference_file_key), Context.MODE_PRIVATE);
SharedPreferences.Editor editor = preferences.edit();
editor.putInt(context.getString(R.string.store_mcp), 0);
editor.commit();
} }
private Object[] quicksort(Object[] array, int low, int high) { private Object[] quicksort(Object[] array, int low, int high) {
......
...@@ -54,4 +54,5 @@ ...@@ -54,4 +54,5 @@
<string name="store_temp">Temperature</string> <string name="store_temp">Temperature</string>
<string name="store_place_type">Place Type</string> <string name="store_place_type">Place Type</string>
<string name="store_place_like">Place Likelihood</string> <string name="store_place_like">Place Likelihood</string>
<string name="store_mcp">Most Common Place</string>
</resources> </resources>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment