Fix review
This commit is contained in:
parent
ad31b0842a
commit
4ef3667c59
2 changed files with 5 additions and 5 deletions
|
@ -1,3 +1,3 @@
|
||||||
package net.osmand.aidlapi.profile;
|
package net.osmand.aidlapi.profile;
|
||||||
|
|
||||||
parcelable ExportSettingsType;
|
parcelable AExportSettingsType;
|
|
@ -2352,11 +2352,11 @@ public class OsmandAidlApi {
|
||||||
}
|
}
|
||||||
List<SettingsHelper.SettingsItem> settingsItems = new ArrayList<>();
|
List<SettingsHelper.SettingsItem> settingsItems = new ArrayList<>();
|
||||||
settingsItems.add(new SettingsHelper.ProfileSettingsItem(app, appMode));
|
settingsItems.add(new SettingsHelper.ProfileSettingsItem(app, appMode));
|
||||||
File tempDir = FileUtils.getTempDir(app);
|
File exportDir = app.getSettings().getExternalStorageDirectory();
|
||||||
String fileName = appMode.toHumanString();
|
String fileName = appMode.toHumanString();
|
||||||
SettingsHelper settingsHelper = app.getSettingsHelper();
|
SettingsHelper settingsHelper = app.getSettingsHelper();
|
||||||
settingsItems.addAll(settingsHelper.getFilteredSettingsItems(settingsHelper.getAdditionalData(), settingsTypes));
|
settingsItems.addAll(settingsHelper.getFilteredSettingsItems(settingsHelper.getAdditionalData(), settingsTypes));
|
||||||
settingsHelper.exportSettings(tempDir, fileName, null, settingsItems, true);
|
settingsHelper.exportSettings(exportDir, fileName, null, settingsItems, true);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
@ -2403,9 +2403,9 @@ public class OsmandAidlApi {
|
||||||
} else if (fileName.endsWith(IndexConstants.GPX_FILE_EXT)) {
|
} else if (fileName.endsWith(IndexConstants.GPX_FILE_EXT)) {
|
||||||
if (destinationDir.startsWith(IndexConstants.GPX_INDEX_DIR)
|
if (destinationDir.startsWith(IndexConstants.GPX_INDEX_DIR)
|
||||||
&& !FILE_TO_SAVE.equals(fileName)) {
|
&& !FILE_TO_SAVE.equals(fileName)) {
|
||||||
showGpx(new File(destinationDir, fileName).getName());
|
destinationDir = destinationDir.replaceFirst(IndexConstants.GPX_INDEX_DIR, "");
|
||||||
|
showGpx(new File(destinationDir, fileName).getPath());
|
||||||
} else if (destinationDir.isEmpty() && FILE_TO_SAVE.equals(fileName)) {
|
} else if (destinationDir.isEmpty() && FILE_TO_SAVE.equals(fileName)) {
|
||||||
GPXUtilities.loadGPXFile(new File(destinationDir, fileName));
|
|
||||||
app.getFavorites().loadFavorites();
|
app.getFavorites().loadFavorites();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue