This commit is contained in:
Victor Shcherb 2015-11-11 17:29:29 +01:00
parent 502a0807e1
commit 79b19b8a21
3 changed files with 4 additions and 4 deletions

View file

@ -143,11 +143,11 @@ public class MapPoiTypes {
return null;
}
public Map<String, PoiType> getAllTranslatedNames() {
public Map<String, PoiType> getAllTranslatedNames(boolean skipNonEditable) {
Map<String, PoiType> translation = new HashMap<String, PoiType>();
for(PoiCategory pc : categories) {
for(PoiType pt : pc.getPoiTypes()) {
if(pt.isReference()) {
if(pt.isReference() || pt.isNotEditableOsm()) {
continue;
}
translation.put(pt.getKeyName().replace('_', ' ').toLowerCase(), pt);

View file

@ -375,7 +375,7 @@ public class AdvancedEditPoiFragment extends Fragment
@Override
protected Map<String, PoiType> doInBackground(Void... params) {
return mapPoiTypes.getAllTranslatedNames();
return mapPoiTypes.getAllTranslatedNames(true);
}
@Override

View file

@ -100,7 +100,7 @@ public class EditPoiDialogFragment extends DialogFragment {
}
node = (Node) getArguments().getSerializable(KEY_AMENITY_NODE);
allTranslatedSubTypes = getMyApplication().getPoiTypes().getAllTranslatedNames();
allTranslatedSubTypes = getMyApplication().getPoiTypes().getAllTranslatedNames(true);
Amenity amenity = (Amenity) getArguments().getSerializable(KEY_AMENITY);
editPoiData = new EditPoiData(amenity, node, allTranslatedSubTypes);