Fix ic_action_favorite icon, fix myLocation icon size

This commit is contained in:
Dima-1 2020-05-07 23:42:19 +03:00
parent 9ba43fe2a9
commit 6d2fadb952
47 changed files with 60 additions and 63 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

View file

@ -23,7 +23,7 @@
android:layout_marginLeft="@dimen/content_padding"
android:layout_marginRight="@dimen/content_padding"
android:layout_marginTop="@dimen/content_padding"
android:src="@drawable/ic_action_fav_dark"
android:src="@drawable/ic_action_favorite"
android:layout_marginStart="@dimen/content_padding"
android:layout_marginEnd="@dimen/content_padding" />

View file

@ -24,7 +24,7 @@
android:layout_width="56dp"
android:layout_height="25dp"
android:layout_gravity="center_vertical"
android:src="@drawable/ic_action_fav_dark"/>
android:src="@drawable/ic_action_favorite"/>
<LinearLayout
android:layout_width="0dp"

View file

@ -20,7 +20,7 @@
android:scaleType="centerInside"
android:layout_width="@dimen/map_button_shadow_width"
android:layout_height="match_parent"
tools:src="@drawable/ic_action_fav_dark"
tools:src="@drawable/ic_action_favorite"
tools:visibility="visible"
android:visibility="gone"/>

View file

@ -62,7 +62,7 @@
android:layout_gravity="center_vertical"
android:layout_marginEnd="@dimen/bottom_sheet_content_margin"
android:layout_marginRight="@dimen/bottom_sheet_content_margin"
tools:src="@drawable/ic_action_flag_dark"/>
tools:src="@drawable/ic_action_flag"/>
<LinearLayout
android:layout_width="0dp"

View file

@ -22,7 +22,7 @@
android:layout_marginRight="16dp"
android:scaleType="centerInside"
android:tint="?attr/default_icon_color"
android:src="@drawable/ic_action_flag_dark"
android:src="@drawable/ic_action_flag"
android:layout_marginEnd="16dp" />
<TextView

View file

@ -78,7 +78,7 @@
android:layout_marginTop="2dp"
android:scaleType="centerInside"
android:tint="?attr/default_icon_color"
android:src="@drawable/ic_action_fav_dark"/>
android:src="@drawable/ic_action_favorite"/>
</LinearLayout>

View file

@ -78,7 +78,7 @@
android:layout_marginTop="2dp"
android:scaleType="centerInside"
android:tint="?attr/default_icon_color"
android:src="@drawable/ic_action_fav_dark"/>
android:src="@drawable/ic_action_favorite"/>
</LinearLayout>

View file

@ -19,7 +19,7 @@
<!--android:scaleType="centerInside"-->
<!--android:tint="@color/color_white"-->
<!--android:background="?attr/selectableItemBackground"-->
<!--android:src="@drawable/ic_action_flag_dark" />-->
<!--android:src="@drawable/ic_action_flag" />-->
<!---->
<!--</LinearLayout>-->
@ -51,7 +51,7 @@
android:scaleType="centerInside"
app:tint="?attr/app_bar_primary_item_color"
android:layout_marginTop="24dp"
android:src="@drawable/ic_action_flag_dark"
android:src="@drawable/ic_action_flag"
android:layout_marginStart="16dp" />
<androidx.appcompat.widget.AppCompatEditText

View file

@ -35,7 +35,7 @@
android:layout_marginRight="8dp"
android:scaleType="centerInside"
android:tint="?attr/default_icon_color"
android:src="@drawable/ic_action_flag_dark"
android:src="@drawable/ic_action_flag"
android:layout_marginEnd="8dp" />
<LinearLayout

View file

@ -50,7 +50,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:src="@drawable/ic_action_fav_dark" />
android:src="@drawable/ic_action_favorite" />
<LinearLayout
android:layout_width="0dp"

View file

@ -31,7 +31,7 @@
android:layout_width="56dp"
android:layout_height="25dp"
android:layout_gravity="center_vertical"
android:src="@drawable/ic_action_fav_dark"/>
android:src="@drawable/ic_action_favorite"/>
<LinearLayout
android:layout_width="0dp"

View file

@ -478,7 +478,7 @@ public class MapMarkersHelper {
int type = group.getType();
if (type != -1) {
header.iconRes = type == MapMarkersGroup.FAVORITES_TYPE
? R.drawable.ic_action_fav_dark : R.drawable.ic_action_polygom_dark;
? R.drawable.ic_action_favorite : R.drawable.ic_action_polygom_dark;
categoriesSubHeader.iconRes = R.drawable.ic_action_filter;
}
header.group = group;

View file

@ -179,7 +179,7 @@ public class EditFavoriteGroupDialogFragment extends MenuBottomSheetDialogFragme
final boolean synced = markersGr != null;
BaseBottomSheetItem markersGroupItem = new SimpleBottomSheetItem.Builder()
.setIcon(getContentIcon(synced ? R.drawable.ic_action_delete_dark : R.drawable.ic_action_flag_dark))
.setIcon(getContentIcon(synced ? R.drawable.ic_action_delete_dark : R.drawable.ic_action_flag))
.setTitle(getString(synced ? R.string.remove_from_map_markers : R.string.shared_string_add_to_map_markers))
.setLayoutId(R.layout.bottom_sheet_item_simple)
.setOnClickListener(new View.OnClickListener() {

View file

@ -386,7 +386,7 @@ public class FavoritesTreeFragment extends OsmandExpandableListFragment implemen
if (!MenuItemCompat.isActionViewExpanded(mi)) {
createMenuItem(menu, IMPORT_FAVOURITES_ID, R.string.shared_string_add_to_favorites, R.drawable.ic_action_plus, MenuItemCompat.SHOW_AS_ACTION_ALWAYS);
createMenuItem(menu, SHARE_ID, R.string.shared_string_share, R.drawable.ic_action_gshare_dark, MenuItemCompat.SHOW_AS_ACTION_ALWAYS);
createMenuItem(menu, SELECT_MAP_MARKERS_ID, R.string.select_map_markers, R.drawable.ic_action_flag_dark, MenuItemCompat.SHOW_AS_ACTION_ALWAYS);
createMenuItem(menu, SELECT_MAP_MARKERS_ID, R.string.select_map_markers, R.drawable.ic_action_flag, MenuItemCompat.SHOW_AS_ACTION_ALWAYS);
createMenuItem(menu, DELETE_ID, R.string.shared_string_delete, R.drawable.ic_action_delete_dark, MenuItemCompat.SHOW_AS_ACTION_ALWAYS);
}
}
@ -413,7 +413,7 @@ public class FavoritesTreeFragment extends OsmandExpandableListFragment implemen
public boolean onCreateActionMode(ActionMode mode, Menu menu) {
enableSelectionMode(true);
createMenuItem(menu, SELECT_MAP_MARKERS_ACTION_MODE_ID, R.string.select_map_markers,
R.drawable.ic_action_flag_dark,
R.drawable.ic_action_flag,
MenuItemCompat.SHOW_AS_ACTION_IF_ROOM);
favoritesSelected.clear();
groupsToDelete.clear();

View file

@ -349,14 +349,14 @@ public class MapActivityActions implements DialogProvider {
adapter.addItem(itemBuilder
.setTitleId(selectedObj instanceof FavouritePoint ? R.string.favourites_context_menu_edit : R.string.shared_string_add, mapActivity)
.setId(MAP_CONTEXT_MENU_ADD_ID)
.setIcon(R.drawable.ic_action_fav_dark)
.setIcon(R.drawable.ic_action_favorite_stroke)
.setOrder(10)
.createItem());
adapter.addItem(itemBuilder
.setTitleId(R.string.shared_string_marker, mapActivity)
.setId(MAP_CONTEXT_MENU_MARKER_ID)
.setOrder(20)
.setIcon(R.drawable.ic_action_flag_dark)
.setIcon(R.drawable.ic_action_flag_stroke)
.createItem());
adapter.addItem(itemBuilder
.setTitleId(R.string.shared_string_share, mapActivity)
@ -788,7 +788,7 @@ public class MapActivityActions implements DialogProvider {
optionsMenuHelper.addItem(new ItemBuilder().setTitleId(R.string.map_markers, mapActivity)
.setId(DRAWER_MAP_MARKERS_ID)
.setIcon(R.drawable.ic_action_flag_dark)
.setIcon(R.drawable.ic_action_flag)
.setListener(new ItemClickListener() {
@Override
public boolean onContextMenuClick(ArrayAdapter<ContextMenuItem> adapter, int itemId, int pos, boolean isChecked, int[] viewCoordinates) {
@ -801,7 +801,7 @@ public class MapActivityActions implements DialogProvider {
optionsMenuHelper.addItem(new ItemBuilder().setTitleId(R.string.shared_string_my_places, mapActivity)
.setId(DRAWER_MY_PLACES_ID)
.setIcon(R.drawable.ic_action_fav_dark)
.setIcon(R.drawable.ic_action_favorite)
.setListener(new ItemClickListener() {
@Override
public boolean onContextMenuClick(ArrayAdapter<ContextMenuItem> adapter, int itemId, int pos, boolean isChecked, int[] viewCoordinates) {

View file

@ -177,7 +177,7 @@ public class SearchPOIActivity extends OsmandListActivity implements OsmAndCompa
});
showOnMapItem.setEnabled(!isNameSearch() || amenityAdapter.getCount() > 0);
if (filter != null && !isNameSearch()) {
createMenuItem(omenu, SAVE_FILTER, R.string.edit_filter_save_as_menu_item, R.drawable.ic_action_fav_dark,
createMenuItem(omenu, SAVE_FILTER, R.string.edit_filter_save_as_menu_item, R.drawable.ic_action_favorite,
MenuItemCompat.SHOW_AS_ACTION_IF_ROOM);
if (!filter.isStandardFilter()) {
createMenuItem(omenu, DELETE_FILTER, R.string.shared_string_delete, R.drawable.ic_action_delete_dark,

View file

@ -180,7 +180,7 @@ public class DashWaypointsFragment extends DashLocationFragment {
MenuItem item;
// item = optionsMenu.getMenu().add(
// R.string.shared_string_add_to_favorites).setIcon(getMyApplication().getIconsCache().
// getIcon(R.drawable.ic_action_fav_dark));
// getIcon(R.drawable.ic_action_favorite));
// item.setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
// @Override
// public boolean onMenuItemClick(MenuItem item) {

View file

@ -405,8 +405,10 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, IRouteInfo
actionButton = new ImageView(mapActivity);
int btnSizePx = mapActivity.getResources().getDimensionPixelSize(R.dimen.map_button_size);
actionButton.setLayoutParams(getActionButtonLayoutParams(btnSizePx));
actionButton.setScaleType(ScaleType.CENTER);
actionButton.setBackgroundResource(R.drawable.btn_circle_blue);
int iconSizePx = mapActivity.getResources().getDimensionPixelSize(R.dimen.standard_icon_size);
int iconPadding = (btnSizePx - iconSizePx) / 2;
actionButton.setPadding(iconPadding, iconPadding, iconPadding, iconPadding);
hideActionButton();

View file

@ -38,7 +38,6 @@ import net.osmand.plus.GpxSelectionHelper;
import net.osmand.plus.OsmandApplication;
import net.osmand.plus.OsmandPlugin;
import net.osmand.plus.OsmandSettings;
import net.osmand.plus.OsmandSettings.OsmandPreference;
import net.osmand.plus.OsmandSettings.CommonPreference;
import net.osmand.plus.OsmandSettings.ListStringPreference;
import net.osmand.plus.R;
@ -372,7 +371,7 @@ public class ConfigureMapMenu {
.setTitleId(R.string.shared_string_favorites, activity)
.setSelected(settings.SHOW_FAVORITES.get())
.setColor(selected ? R.color.osmand_orange : ContextMenuItem.INVALID_ID)
.setIcon(R.drawable.ic_action_fav_dark)
.setIcon(R.drawable.ic_action_favorite)
.setItemDeleteAction(makeDeleteAction(settings.SHOW_FAVORITES))
.setListener(l)
.createItem());
@ -443,7 +442,7 @@ public class ConfigureMapMenu {
.setTitleId(R.string.map_markers, activity)
.setSelected(selected)
.setColor(selected ? R.color.osmand_orange : ContextMenuItem.INVALID_ID)
.setIcon(R.drawable.ic_action_flag_dark)
.setIcon(R.drawable.ic_action_flag)
.setItemDeleteAction(makeDeleteAction(settings.SHOW_MAP_MARKERS))
.setListener(l).createItem());

View file

@ -1257,7 +1257,7 @@ public class ImportHelper {
items.add(new ShortDescriptionItem(txt));
BaseBottomSheetItem asFavoritesItem = new SimpleBottomSheetItem.Builder()
.setIcon(getContentIcon(R.drawable.ic_action_fav_dark))
.setIcon(getContentIcon(R.drawable.ic_action_favorite))
.setTitle(getString(R.string.import_as_favorites))
.setLayoutId(R.layout.bottom_sheet_item_simple)
.setOnClickListener(new View.OnClickListener() {

View file

@ -80,7 +80,7 @@ public class MapMarkerDialogHelper {
.getColor(useCenter ? R.color.color_distance : R.color.color_myloc_distance));
} else {
waypointIcon.setImageDrawable(app.getUIUtilities()
.getIcon(R.drawable.ic_action_flag_dark, !nightMode));
.getIcon(R.drawable.ic_action_flag, !nightMode));
AndroidUtils.setTextSecondaryColor(ctx, text, nightMode);
AndroidUtils.setTextSecondaryColor(ctx, textDist, nightMode);
}
@ -114,6 +114,6 @@ public class MapMarkerDialogHelper {
}
public static Drawable getMapMarkerIcon(OsmandApplication app, int colorIndex) {
return app.getUIUtilities().getIcon(R.drawable.ic_action_flag_dark, MapMarker.getColorId(colorIndex));
return app.getUIUtilities().getIcon(R.drawable.ic_action_flag, MapMarker.getColorId(colorIndex));
}
}

View file

@ -908,8 +908,8 @@ public class MapContextMenu extends MenuTitleController implements StateChangedL
favActionIconId = menuController.getFavActionIconId();
waypointActionIconId = menuController.getWaypointActionIconId();
} else {
favActionIconId = R.drawable.ic_action_fav_dark;
waypointActionIconId = R.drawable.ic_action_flag_dark;
favActionIconId = R.drawable.ic_action_favorite_stroke;
waypointActionIconId = R.drawable.ic_action_flag_stroke;
}
}

View file

@ -504,7 +504,7 @@ public abstract class MenuController extends BaseMenuController implements Colla
}
public int getFavActionIconId() {
return R.drawable.ic_action_fav_dark;
return R.drawable.ic_action_favorite_stroke;
}
public int getFavActionStringId() {
@ -516,7 +516,7 @@ public abstract class MenuController extends BaseMenuController implements Colla
}
public int getWaypointActionIconId() {
return R.drawable.ic_action_flag_dark;
return R.drawable.ic_action_flag_stroke;
}
public int getWaypointActionStringId() {

View file

@ -119,7 +119,7 @@ public class MapMarkerEditorFragment extends PointEditorFragment {
@Override
public Drawable getNameIcon() {
return requireMyApplication().getUIUtilities().getIcon(R.drawable.ic_action_flag_dark, getPointColor());
return requireMyApplication().getUIUtilities().getIcon(R.drawable.ic_action_flag, getPointColor());
}
@Override

View file

@ -49,7 +49,7 @@ public class HistoryMarkerMenuBottomSheetDialogFragment extends MenuBottomSheetD
BaseBottomSheetItem markerItem = new BottomSheetItemWithDescription.Builder()
.setDescription(getString(R.string.passed, month + " " + day))
.setIcon(getIcon(R.drawable.ic_action_flag_dark, MapMarker.getColorId(markerColorIndex)))
.setIcon(getIcon(R.drawable.ic_action_flag, MapMarker.getColorId(markerColorIndex)))
.setTitle(markerName)
.setLayoutId(R.layout.bottom_sheet_item_with_descr_56dp)
.create();

View file

@ -27,7 +27,7 @@ public class SelectionMarkersGroupBottomSheetDialogFragment extends MenuBottomSh
items.add(new ShortDescriptionItem(getString(R.string.add_group_descr)));
BaseBottomSheetItem favoritesItem = new SimpleBottomSheetItem.Builder()
.setIcon(getContentIcon(R.drawable.ic_action_fav_dark))
.setIcon(getContentIcon(R.drawable.ic_action_favorite))
.setTitle(getString(R.string.favourites_group))
.setLayoutId(R.layout.bottom_sheet_item_simple)
.setOnClickListener(new View.OnClickListener() {

View file

@ -96,7 +96,7 @@ public class MapMarkersActiveAdapter extends RecyclerView.Adapter<MapMarkerItemV
} else {
holder.iconDirection.setVisibility(View.VISIBLE);
holder.icon.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_flag_dark, markerColor));
holder.icon.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_flag, markerColor));
holder.mainLayout.setBackgroundColor(ContextCompat.getColor(mapActivity, night ? R.color.list_background_color_dark : R.color.list_background_color_light));
holder.title.setTextColor(ContextCompat.getColor(mapActivity, night ? R.color.text_color_primary_dark : R.color.text_color_primary_light));
holder.divider.setBackgroundColor(ContextCompat.getColor(mapActivity, night ? R.color.app_bar_color_dark : R.color.divider_color_light));

View file

@ -291,7 +291,7 @@ public class MapMarkersGroupsAdapter extends RecyclerView.Adapter<RecyclerView.V
} else {
itemViewHolder.iconDirection.setVisibility(View.VISIBLE);
itemViewHolder.icon.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_flag_dark, color));
itemViewHolder.icon.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_flag, color));
itemViewHolder.mainLayout.setBackgroundColor(ContextCompat.getColor(mapActivity, night ? R.color.list_background_color_dark : R.color.list_background_color_light));
itemViewHolder.title.setTextColor(ContextCompat.getColor(mapActivity, night ? R.color.text_color_primary_dark : R.color.text_color_primary_light));
itemViewHolder.divider.setBackgroundColor(ContextCompat.getColor(mapActivity, night ? R.color.app_bar_color_dark : R.color.divider_color_light));

View file

@ -121,7 +121,7 @@ public class MapMarkersHistoryAdapter extends RecyclerView.Adapter<RecyclerView.
int color = night ? R.color.icon_color_default_dark : R.color.icon_color_default_light;
int actionIconColor = night ? R.color.icon_color_primary_dark : R.color.icon_color_primary_light;
itemViewHolder.icon.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_flag_dark, color));
itemViewHolder.icon.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_flag, color));
itemViewHolder.title.setText(marker.getName(app));

View file

@ -157,7 +157,7 @@ public class MapMarkersListAdapter extends RecyclerView.Adapter<MapMarkerItemVie
if (location != null) {
holder.icon.setImageDrawable(ContextCompat.getDrawable(mapActivity, R.drawable.ic_action_location_color));
} else {
int res = start ? R.drawable.ic_action_point_start : (finish ? R.drawable.ic_action_point_destination : R.drawable.ic_action_flag_dark);
int res = start ? R.drawable.ic_action_point_start : (finish ? R.drawable.ic_action_point_destination : R.drawable.ic_action_flag);
holder.icon.setImageDrawable(iconsCache.getIcon(res, MapMarker.getColorId(marker.colorIndex)));
}

View file

@ -399,9 +399,9 @@ public class TrackPointFragment extends OsmandExpandableListFragment implements
final MapMarkersHelper markersHelper = app.getMapMarkersHelper();
final boolean synced = markersHelper.getMarkersGroup(getGpx()) != null;
createMenuItem(menu, SELECT_MAP_MARKERS_ID, synced ? R.string.remove_from_map_markers
: R.string.shared_string_add_to_map_markers, R.drawable.ic_action_flag_dark, MenuItem.SHOW_AS_ACTION_NEVER);
: R.string.shared_string_add_to_map_markers, R.drawable.ic_action_flag, MenuItem.SHOW_AS_ACTION_NEVER);
}
createMenuItem(menu, SELECT_FAVORITES_ID, R.string.shared_string_add_to_favorites, R.drawable.ic_action_fav_dark, MenuItem.SHOW_AS_ACTION_NEVER);
createMenuItem(menu, SELECT_FAVORITES_ID, R.string.shared_string_add_to_favorites, R.drawable.ic_action_favorite, MenuItem.SHOW_AS_ACTION_NEVER);
createMenuItem(menu, DELETE_ID, R.string.shared_string_delete, R.drawable.ic_action_delete_dark, MenuItem.SHOW_AS_ACTION_NEVER);
createMenuItem(menu, COORDINATE_INPUT_ID, R.string.coordinate_input, R.drawable.ic_action_coordinates_longitude, MenuItem.SHOW_AS_ACTION_NEVER);
}
@ -566,7 +566,7 @@ public class TrackPointFragment extends OsmandExpandableListFragment implements
public boolean onCreateActionMode(ActionMode mode, Menu menu) {
setSelectionMode(true);
createMenuItem(menu, SELECT_FAVORITES_ACTION_MODE_ID, R.string.shared_string_add_to_favorites,
R.drawable.ic_action_fav_dark,
R.drawable.ic_action_favorite,
MenuItem.SHOW_AS_ACTION_IF_ROOM);
selectedItems.clear();
selectedGroups.clear();

View file

@ -31,7 +31,7 @@ public class FavoriteAction extends QuickAction {
public static final QuickActionType TYPE = new QuickActionType(3,
"fav.add", FavoriteAction.class).
nameRes(R.string.quick_action_add_favorite).iconRes(R.drawable.ic_action_fav_dark).
nameRes(R.string.quick_action_add_favorite).iconRes(R.drawable.ic_action_favorite).
category(QuickActionType.CREATE_CATEGORY);
public static final String KEY_NAME = "name";
public static final String KEY_DIALOG = "dialog";

View file

@ -24,7 +24,7 @@ public class GPXAction extends QuickAction {
public static final QuickActionType TYPE = new QuickActionType(6,
"gpx.add", GPXAction.class).
nameRes(R.string.quick_action_add_gpx).iconRes(R.drawable.ic_action_flag_dark).
nameRes(R.string.quick_action_add_gpx).iconRes(R.drawable.ic_action_flag).
category(QuickActionType.CREATE_CATEGORY);
public static final String KEY_NAME = "name";

View file

@ -16,7 +16,7 @@ public class MarkerAction extends QuickAction {
public static final QuickActionType TYPE = new QuickActionType(2,
"marker.add", MarkerAction.class).
nameRes(R.string.quick_action_add_marker).iconRes(R.drawable.ic_action_flag_dark).nonEditable().
nameRes(R.string.quick_action_add_marker).iconRes(R.drawable.ic_action_flag).nonEditable().
category(QuickActionType.CREATE_CATEGORY);

View file

@ -8,7 +8,6 @@ import android.widget.TextView;
import net.osmand.plus.OsmandApplication;
import net.osmand.plus.R;
import net.osmand.plus.activities.MapActivity;
import net.osmand.plus.audionotes.TakeVideoNoteAction;
import net.osmand.plus.quickaction.QuickAction;
import net.osmand.plus.quickaction.QuickActionType;
@ -16,7 +15,7 @@ public class ShowHideFavoritesAction extends QuickAction {
public static final QuickActionType TYPE = new QuickActionType(4,
"favorites.showhide", ShowHideFavoritesAction.class).
nameRes(R.string.quick_action_showhide_favorites_title).iconRes(R.drawable.ic_action_fav_dark).nonEditable().
nameRes(R.string.quick_action_showhide_favorites_title).iconRes(R.drawable.ic_action_favorite).nonEditable().
category(QuickActionType.CONFIGURE_MAP);

View file

@ -637,7 +637,7 @@ public class AddPointBottomSheetDialog extends MenuBottomSheetDialogFragment {
ItemViewHolder favoriteViewHolder = (ItemViewHolder) holder;
if (item.equals(FAVORITES)) {
favoriteViewHolder.title.setText(R.string.shared_string_favorites);
favoriteViewHolder.icon.setImageDrawable(getContentIcon(R.drawable.ic_action_fav_dark));
favoriteViewHolder.icon.setImageDrawable(getContentIcon(R.drawable.ic_action_favorite));
favoriteViewHolder.description.setVisibility(View.GONE);
} else {
if (item instanceof FavouritePoint) {
@ -656,7 +656,7 @@ public class AddPointBottomSheetDialog extends MenuBottomSheetDialogFragment {
favoriteViewHolder.description.setText(point.getCategory());
}
int color = app.getFavorites().getColorWithCategory(point, ContextCompat.getColor(app, R.color.color_favorite));
favoriteViewHolder.icon.setImageDrawable(app.getUIUtilities().getPaintedIcon(R.drawable.ic_action_fav_dark, color));
favoriteViewHolder.icon.setImageDrawable(app.getUIUtilities().getPaintedIcon(R.drawable.ic_action_favorite, color));
}
favoriteViewHolder.description.setVisibility(View.VISIBLE);
}
@ -679,7 +679,7 @@ public class AddPointBottomSheetDialog extends MenuBottomSheetDialogFragment {
ItemViewHolder markerViewHolder = (ItemViewHolder) holder;
if (item.equals(MARKERS)) {
markerViewHolder.title.setText(R.string.shared_string_markers);
markerViewHolder.icon.setImageDrawable(getContentIcon(R.drawable.ic_action_flag_dark));
markerViewHolder.icon.setImageDrawable(getContentIcon(R.drawable.ic_action_flag));
} else {
MapMarker marker = (MapMarker) getItem(position);
markerViewHolder.title.setText(marker.getName(getContext()));

View file

@ -380,7 +380,7 @@ public class QuickSearchListItem {
case FAVORITE_GROUP:
FavoriteGroup group = (FavoriteGroup) searchResult.object;
int color = group.getColor() == 0 ? ContextCompat.getColor(app, R.color.color_favorite) : group.getColor();
return app.getUIUtilities().getPaintedIcon(R.drawable.ic_action_fav_dark, color | 0xff000000);
return app.getUIUtilities().getPaintedIcon(R.drawable.ic_action_favorite, color | 0xff000000);
case REGION:
return getIcon(app, R.drawable.ic_world_globe_dark);
case RECENT_OBJ:

View file

@ -1166,15 +1166,12 @@ public class MapControlsLayer extends OsmandMapLayer {
if (compass) {
((ImageView) iv).setImageDrawable(new CompassDrawable(d));
} else {
int iconSize = (int) ctx.getResources().getDimension(R.dimen.standard_icon_size);
Bitmap bitmap = Bitmap.createBitmap(iconSize, iconSize, Bitmap.Config.ARGB_8888);
Canvas canvas = new Canvas(bitmap);
canvas.drawColor(0, PorterDuff.Mode.CLEAR);
if (d != null) {
d.setBounds(0, 0, canvas.getWidth(), canvas.getHeight());
d.draw(canvas);
}
((ImageView) iv).setImageDrawable(new BitmapDrawable(ctx.getResources(), bitmap));
int btnSizePx = (iv).getLayoutParams().height;
int iconSizePx = (int) ctx.getResources().getDimension(R.dimen.standard_icon_size);
int iconPadding = (btnSizePx - iconSizePx) / 2;
iv.setPadding(iconPadding, iconPadding, iconPadding, iconPadding);
((ImageView) iv).setScaleType(ImageView.ScaleType.FIT_CENTER);
((ImageView) iv).setImageDrawable(d);
}
} else if (iv instanceof TextView) {
((TextView) iv).setCompoundDrawablesWithIntrinsicBounds(

View file

@ -203,11 +203,11 @@ public class MapInfoLayer extends OsmandMapLayer {
TextInfoWidget marker = mwf.createMapMarkerControl(map, true);
registerSideWidget(marker, R.drawable.ic_action_flag_dark, R.string.map_marker_1st, WIDGET_MARKER_1, false, 17);
registerSideWidget(marker, R.drawable.ic_action_flag, R.string.map_marker_1st, WIDGET_MARKER_1, false, 17);
TextInfoWidget bearing = ric.createBearingControl(map);
registerSideWidget(bearing, new BearingWidgetState(app), WIDGET_BEARING, false, 18);
TextInfoWidget marker2nd = mwf.createMapMarkerControl(map, false);
registerSideWidget(marker2nd, R.drawable.ic_action_flag_dark, R.string.map_marker_2nd, WIDGET_MARKER_2, false, 19);
registerSideWidget(marker2nd, R.drawable.ic_action_flag, R.string.map_marker_2nd, WIDGET_MARKER_2, false, 19);
TextInfoWidget speed = ric.createSpeedControl(map);
registerSideWidget(speed, R.drawable.ic_action_speed, R.string.map_widget_speed, WIDGET_SPEED, false, 20);