Update
This commit is contained in:
parent
a633e19a76
commit
4e2b0057ac
8 changed files with 46 additions and 37 deletions
|
@ -21,6 +21,11 @@ public abstract class AbstractPoiType {
|
|||
return keyName;
|
||||
}
|
||||
|
||||
public String getIconKeyName() {
|
||||
return keyName.replace(':', '_');
|
||||
}
|
||||
|
||||
|
||||
public String getTranslation() {
|
||||
return registry.getTranslation(this);
|
||||
}
|
||||
|
|
|
@ -112,11 +112,38 @@
|
|||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
|
||||
<!-- CENTER -->
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content" >
|
||||
|
||||
<!-- CENTER -->
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="top|left"
|
||||
android:layout_marginLeft="@dimen/map_button_margin"
|
||||
android:layout_marginTop="@dimen/map_button_margin"
|
||||
android:orientation="horizontal" >
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/map_layers_button"
|
||||
android:layout_width="@dimen/map_small_button_size"
|
||||
android:layout_height="@dimen/map_small_button_size"
|
||||
android:background="@drawable/btn_inset_circle_trans"
|
||||
android:src="@drawable/ic_action_test_light" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/map_compass_button"
|
||||
android:layout_width="@dimen/map_small_button_size"
|
||||
android:layout_marginLeft="@dimen/map_small_button_margin"
|
||||
android:layout_height="@dimen/map_small_button_size"
|
||||
android:background="@drawable/btn_inset_circle_trans"
|
||||
android:src="@drawable/ic_action_test_light" />
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/map_center_info"
|
||||
|
@ -154,30 +181,6 @@
|
|||
android:progress="60"
|
||||
android:visibility="gone" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="top|left"
|
||||
android:layout_marginLeft="@dimen/map_button_margin"
|
||||
android:layout_marginTop="@dimen/map_button_margin"
|
||||
android:orientation="horizontal" >
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/map_layers_button"
|
||||
android:layout_width="@dimen/map_small_button_size"
|
||||
android:layout_height="@dimen/map_small_button_size"
|
||||
android:background="@drawable/btn_inset_circle"
|
||||
android:src="@drawable/ic_action_test_light" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/map_compass_button"
|
||||
android:layout_width="@dimen/map_small_button_size"
|
||||
android:layout_marginLeft="@dimen/map_small_button_margin"
|
||||
android:layout_height="@dimen/map_small_button_size"
|
||||
android:background="@drawable/btn_inset_circle"
|
||||
android:src="@drawable/ic_action_test_light" />
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
@ -211,7 +214,7 @@
|
|||
android:layout_width="@dimen/map_small_button_size"
|
||||
android:layout_height="@dimen/map_small_button_size"
|
||||
android:layout_gravity="top|center_horizontal"
|
||||
android:background="@drawable/btn_inset_circle"
|
||||
android:background="@drawable/btn_inset_circle_trans"
|
||||
android:src="@drawable/ic_action_test_light" />
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
|
|
|
@ -127,7 +127,7 @@
|
|||
android:id="@+id/map_layers_button"
|
||||
android:layout_width="@dimen/map_small_button_size"
|
||||
android:layout_height="@dimen/map_small_button_size"
|
||||
android:background="@drawable/btn_inset_circle"
|
||||
android:background="@drawable/btn_inset_circle_trans"
|
||||
android:src="@drawable/ic_action_test_light" />
|
||||
|
||||
<ImageButton
|
||||
|
@ -192,7 +192,7 @@
|
|||
android:layout_width="@dimen/map_small_button_size"
|
||||
android:layout_height="@dimen/map_small_button_size"
|
||||
android:layout_gravity="top|center_horizontal"
|
||||
android:background="@drawable/btn_inset_circle"
|
||||
android:background="@drawable/btn_inset_circle_trans"
|
||||
android:src="@drawable/ic_action_test_light" />
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
|
|
|
@ -775,8 +775,8 @@ public class SearchPOIActivity extends OsmandListActivity implements OsmAndCompa
|
|||
direction.setImageDrawable(draw);
|
||||
PoiType st = amenity.getType().getPoiTypeByKeyName(amenity.getSubType());
|
||||
if (st != null) {
|
||||
if (RenderingIcons.containsBigIcon(st.getKeyName())) {
|
||||
icon.setImageResource(RenderingIcons.getBigIconResourceId(st.getKeyName()));
|
||||
if (RenderingIcons.containsBigIcon(st.getIconKeyName())) {
|
||||
icon.setImageResource(RenderingIcons.getBigIconResourceId(st.getIconKeyName()));
|
||||
} else if (RenderingIcons.containsBigIcon(st.getOsmTag() + "_" + st.getOsmValue())) {
|
||||
icon.setImageResource(RenderingIcons.getBigIconResourceId(st.getOsmTag() + "_" + st.getOsmValue()));
|
||||
} else {
|
||||
|
|
|
@ -255,8 +255,8 @@ public class SearchPoiFilterFragment extends ListFragment implements SearchActiv
|
|||
name = model.getName();
|
||||
} else {
|
||||
AbstractPoiType st = (AbstractPoiType) item;
|
||||
if (RenderingIcons.containsBigIcon(st.getKeyName())) {
|
||||
icon.setImageDrawable(RenderingIcons.getBigIcon(getActivity(), st.getKeyName()));
|
||||
if (RenderingIcons.containsBigIcon(st.getIconKeyName())) {
|
||||
icon.setImageDrawable(RenderingIcons.getBigIcon(getActivity(), st.getIconKeyName()));
|
||||
} else if (st instanceof PoiType
|
||||
&& RenderingIcons.containsBigIcon(((PoiType) st).getOsmTag() + "_"
|
||||
+ ((PoiType) st).getOsmValue())) {
|
||||
|
|
|
@ -388,7 +388,8 @@ public class ConfigureMapMenu {
|
|||
ctx.getString(R.string.lang_es), ctx.getString(R.string.lang_fi), ctx.getString(R.string.lang_fr),
|
||||
ctx.getString(R.string.lang_he), ctx.getString(R.string.lang_hi), ctx.getString(R.string.lang_hr),
|
||||
ctx.getString(R.string.lang_hu), ctx.getString(R.string.lang_it), ctx.getString(R.string.lang_ja),
|
||||
ctx.getString(R.string.lang_ko), ctx.getString(R.string.lang_lv), ctx.getString(R.string.lang_nl),
|
||||
ctx.getString(R.string.lang_ko), ctx.getString(R.string.lang_lt),
|
||||
ctx.getString(R.string.lang_lv), ctx.getString(R.string.lang_nl),
|
||||
ctx.getString(R.string.lang_pl), ctx.getString(R.string.lang_ro), ctx.getString(R.string.lang_ru),
|
||||
ctx.getString(R.string.lang_sk), ctx.getString(R.string.lang_sl), ctx.getString(R.string.lang_sv),
|
||||
ctx.getString(R.string.lang_sw), ctx.getString(R.string.lang_zh) };
|
||||
|
|
|
@ -666,9 +666,9 @@ public class WaypointHelper {
|
|||
Amenity amenity = ((AmenityLocationPoint) point).a;
|
||||
PoiType st = amenity.getType().getPoiTypeByKeyName(amenity.getSubType());
|
||||
if (st != null) {
|
||||
if (RenderingIcons.containsBigIcon(st.getKeyName())) {
|
||||
if (RenderingIcons.containsBigIcon(st.getIconKeyName())) {
|
||||
return uiCtx.getResources().getDrawable(
|
||||
RenderingIcons.getBigIconResourceId(st.getKeyName()));
|
||||
RenderingIcons.getBigIconResourceId(st.getIconKeyName()));
|
||||
} else if (RenderingIcons.containsBigIcon(st.getOsmTag() + "_" + st.getOsmValue())) {
|
||||
return uiCtx.getResources().getDrawable(
|
||||
RenderingIcons.getBigIconResourceId(st.getOsmTag() + "_" + st.getOsmValue()));
|
||||
|
|
|
@ -208,8 +208,8 @@ public class POIMapLayer extends OsmandMapLayer implements ContextMenuLayer.ICon
|
|||
String id = null;
|
||||
PoiType st = o.getType().getPoiTypeByKeyName(o.getSubType());
|
||||
if (st != null) {
|
||||
if (RenderingIcons.containsIcon(st.getKeyName())) {
|
||||
id = st.getKeyName();
|
||||
if (RenderingIcons.containsIcon(st.getIconKeyName())) {
|
||||
id = st.getIconKeyName();
|
||||
} else if (RenderingIcons.containsIcon(st.getOsmTag() + "_" + st.getOsmValue())) {
|
||||
id = st.getOsmTag() + "_" + st.getOsmValue();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue