Backup markers
This commit is contained in:
parent
fbcf727a25
commit
5df52cd5ed
2 changed files with 5 additions and 3 deletions
|
@ -6,6 +6,8 @@ import android.app.backup.BackupAgentHelper;
|
|||
import android.app.backup.FileBackupHelper;
|
||||
import android.app.backup.SharedPreferencesBackupHelper;
|
||||
|
||||
import net.osmand.plus.mapmarkers.MapMarkersDbHelper;
|
||||
|
||||
/**
|
||||
* Requires android API from android-8
|
||||
*/
|
||||
|
@ -25,7 +27,7 @@ public class OsmandBackupAgent extends BackupAgentHelper {
|
|||
SharedPreferencesBackupHelper helper = new SharedPreferencesBackupHelper(this, prefs);
|
||||
addHelper("osmand.settings", helper);
|
||||
|
||||
FileBackupHelper fileBackupHelper = new FileBackupHelper(this, FavouritesDbHelper.FILE_TO_BACKUP);
|
||||
addHelper(FavouritesDbHelper.FILE_TO_BACKUP, fileBackupHelper);
|
||||
FileBackupHelper fileBackupHelper = new FileBackupHelper(this, FavouritesDbHelper.FILE_TO_BACKUP, "../databases/" + MapMarkersDbHelper.DB_NAME);
|
||||
addHelper("osmand.files", fileBackupHelper);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ import java.util.Random;
|
|||
public class MapMarkersDbHelper {
|
||||
|
||||
private static final int DB_VERSION = 2;
|
||||
private static final String DB_NAME = "map_markers_db";
|
||||
public static final String DB_NAME = "map_markers_db";
|
||||
|
||||
private static final String MARKERS_TABLE_NAME = "map_markers";
|
||||
private static final String MARKERS_COL_ID = "marker_id";
|
||||
|
|
Loading…
Reference in a new issue