diff --git a/OsmAnd/res/values-fa/strings.xml b/OsmAnd/res/values-fa/strings.xml
index 508987b29f..32cb75fa9b 100644
--- a/OsmAnd/res/values-fa/strings.xml
+++ b/OsmAnd/res/values-fa/strings.xml
@@ -611,7 +611,7 @@
صدا/تصویر در حال ضبط میباشد. برای متوقف کردن آن ویجت AV را بزنید.
صدایی از ضبط مورد نظر درحال پخش میباشد.\n%1$s
آیا میخواهید این مورد ضبط شده را پاک کنید؟
- ضبط %1$s%2$ s از %3$s
+ ضبط %1$s%2$s از %3$s
افزونه OsmAnd برای منحنی های همتراز آفلاین
استفاده از حسگر مغناطیسی به جای سنسور جهت یابی برای استفاده در قطب نما
نشان دادن POI
diff --git a/OsmAnd/src/net/osmand/plus/activities/EditPOIFilterActivity.java b/OsmAnd/src/net/osmand/plus/activities/EditPOIFilterActivity.java
index d5d45e970f..1b0ee81f91 100644
--- a/OsmAnd/src/net/osmand/plus/activities/EditPOIFilterActivity.java
+++ b/OsmAnd/src/net/osmand/plus/activities/EditPOIFilterActivity.java
@@ -63,17 +63,21 @@ public class EditPOIFilterActivity extends OsmandListActivity {
public void onCreate(final Bundle icicle) {
Bundle bundle = this.getIntent().getExtras();
String filterId = bundle.getString(AMENITY_FILTER);
- helper = ((OsmandApplication)getApplication()).getPoiFilters();
+ helper = ((OsmandApplication) getApplication()).getPoiFilters();
filter = helper.getFilterById(filterId);
super.onCreate(icicle);
-
-
+
setContentView(R.layout.editing_poi_filter);
getSupportActionBar().setTitle(R.string.filterpoi_activity);
getSupportActionBar().setIcon(R.drawable.tab_search_poi_icon);
-
- getSupportActionBar().setSubtitle(filter.getName());
- setListAdapter(new AmenityAdapter(AmenityType.getCategories()));
+
+ if (filter != null) {
+ getSupportActionBar().setSubtitle(filter.getName());
+ setListAdapter(new AmenityAdapter(AmenityType.getCategories()));
+ } else {
+ setListAdapter(new AmenityAdapter(new AmenityType[0]));
+ }
+
}
@@ -94,6 +98,9 @@ public class EditPOIFilterActivity extends OsmandListActivity {
@Override
public boolean onCreateOptionsMenu(Menu menu) {
+ if(filter == null) {
+ return super.onCreateOptionsMenu(menu);
+ }
createMenuItem(menu, SAVE_FILTER, R.string.edit_filter_save_as_menu_item,
R.drawable.ic_action_gsave_light, R.drawable.ic_action_gsave_dark ,
MenuItem.SHOW_AS_ACTION_IF_ROOM);
diff --git a/OsmAnd/src/net/osmand/plus/audionotes/SettingsAudioVideoActivity.java b/OsmAnd/src/net/osmand/plus/audionotes/SettingsAudioVideoActivity.java
index 931a38d2ad..2622fef45b 100644
--- a/OsmAnd/src/net/osmand/plus/audionotes/SettingsAudioVideoActivity.java
+++ b/OsmAnd/src/net/osmand/plus/audionotes/SettingsAudioVideoActivity.java
@@ -81,8 +81,8 @@ public class SettingsAudioVideoActivity extends SettingsBaseActivity {
itemsValues.add(AV_CAMERA_FOCUS_CONTINUOUS);
}
}
- entries = items.toArray(entries);
- intValues = itemsValues.toArray(intValues);
+ entries = items.toArray(new String[items.size()]);
+ intValues = itemsValues.toArray(new Integer[itemsValues.size()]);
if (entries.length > 0) {
ListPreference camFocus = createListPreference(p.AV_CAMERA_FOCUS_TYPE, entries, intValues, R.string.av_camera_focus,
R.string.av_camera_focus_descr);
diff --git a/OsmAnd/src/net/osmand/plus/base/MapViewTrackingUtilities.java b/OsmAnd/src/net/osmand/plus/base/MapViewTrackingUtilities.java
index 676a4be767..a8b4eccaee 100644
--- a/OsmAnd/src/net/osmand/plus/base/MapViewTrackingUtilities.java
+++ b/OsmAnd/src/net/osmand/plus/base/MapViewTrackingUtilities.java
@@ -259,7 +259,9 @@ public class MapViewTrackingUtilities implements OsmAndLocationListener, IMapLoc
}
app.showShortToastMessage(resId);
updateSettings();
- mapView.refreshMap();
+ if(mapView != null) {
+ mapView.refreshMap();
+ }
}
}
diff --git a/OsmAnd/src/net/osmand/plus/resources/ResourceManager.java b/OsmAnd/src/net/osmand/plus/resources/ResourceManager.java
index f3a6c82d6f..60b726594e 100644
--- a/OsmAnd/src/net/osmand/plus/resources/ResourceManager.java
+++ b/OsmAnd/src/net/osmand/plus/resources/ResourceManager.java
@@ -443,6 +443,8 @@ public class ResourceManager {
context.getSettings().PREVIOUS_INSTALLED_VERSION.set(Version.getFullVersion(context));
context.getPoiFilters().updateFilters(false);
+ } catch (SQLiteException e) {
+ log.error(e.getMessage(), e);
} catch (IOException e) {
log.error(e.getMessage(), e);
} catch (XmlPullParserException e) {