Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
4120563c95
10 changed files with 95 additions and 80 deletions
|
@ -21,6 +21,11 @@ public abstract class AbstractPoiType {
|
|||
return keyName;
|
||||
}
|
||||
|
||||
public String getIconKeyName() {
|
||||
return keyName.replace(':', '_');
|
||||
}
|
||||
|
||||
|
||||
public String getTranslation() {
|
||||
return registry.getTranslation(this);
|
||||
}
|
||||
|
|
|
@ -101,8 +101,8 @@ public class BinaryRoutePlanner {
|
|||
if(TRACE_ROUTING){
|
||||
printRoad(">", segment, !forwardSearch);
|
||||
}
|
||||
if(segment.getParentRoute() != null)
|
||||
System.out.println(segment.getRoad().getId() + " - " + segment.getParentRoute().getRoad().getId());
|
||||
// if(segment.getParentRoute() != null)
|
||||
// System.out.println(segment.getRoad().getId() + " - " + segment.getParentRoute().getRoad().getId());
|
||||
if(segment instanceof FinalRouteSegment) {
|
||||
if(RoutingContext.SHOW_GC_SIZE){
|
||||
log.warn("Estimated overhead " + (ctx.memoryOverhead / (1<<20))+ " mb");
|
||||
|
|
|
@ -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
|
||||
|
@ -147,45 +147,7 @@
|
|||
android:layout_weight="0.6" >
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
<!-- CENTER -->
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/map_center_info"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="top|center"
|
||||
android:layout_marginTop="@dimen/map_button_margin"
|
||||
android:background="@drawable/btn_round"
|
||||
android:visibility="gone"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/map_lanes"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/map_lanes_dist_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:layout_weight="1"
|
||||
android:maxLines="1"
|
||||
android:text="1048 km"
|
||||
android:textColor="@color/color_black"
|
||||
android:textSize="@dimen/map_widget_text_size_small" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/map_horizontal_progress"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="@dimen/map_routing_progress_width"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/map_button_margin"
|
||||
android:layout_marginRight="@dimen/map_button_margin"
|
||||
android:max="100"
|
||||
android:progress="60"
|
||||
android:visibility="gone" />
|
||||
</LinearLayout>
|
||||
<!-- RIGHT widgets colon -->
|
||||
|
||||
<LinearLayout
|
||||
|
@ -230,11 +192,50 @@
|
|||
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>
|
||||
</LinearLayout>
|
||||
<!-- CENTER -->
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/map_center_info"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="top|center"
|
||||
android:layout_marginTop="@dimen/map_button_margin"
|
||||
android:background="@drawable/btn_round"
|
||||
android:visibility="gone"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/map_lanes"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/map_lanes_dist_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:layout_weight="1"
|
||||
android:maxLines="1"
|
||||
android:text="1048 km"
|
||||
android:textColor="@color/color_black"
|
||||
android:textSize="@dimen/map_widget_text_size_small" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/map_horizontal_progress"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="@dimen/map_routing_progress_width"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/map_button_margin"
|
||||
android:layout_marginRight="@dimen/map_button_margin"
|
||||
android:max="100"
|
||||
android:progress="60"
|
||||
android:visibility="gone" />
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
|
@ -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()));
|
||||
|
|
|
@ -189,8 +189,13 @@ public class OsmandMonitoringPlugin extends OsmandPlugin {
|
|||
if ((last != lastUpdateTime) && (globalRecord || isRecording)) {
|
||||
lastUpdateTime = last;
|
||||
//blink implementation with 2 indicator states (global logging + profile/navigation logging)
|
||||
setIcons(R.drawable.widget_monitoring_rec_inactive_day,
|
||||
R.drawable.widget_monitoring_rec_inactive_night);
|
||||
if (globalRecord) {
|
||||
setIcons(R.drawable.widget_monitoring_rec_small_day,
|
||||
R.drawable.widget_monitoring_rec_small_night);
|
||||
} else {
|
||||
setIcons(R.drawable.widget_monitoring_rec_small_day,
|
||||
R.drawable.widget_monitoring_rec_small_night);
|
||||
}
|
||||
|
||||
map.getMyApplication().runInUIThread(new Runnable() {
|
||||
@Override
|
||||
|
|
|
@ -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