Move drawable padding to code

This commit is contained in:
PavelRatushny 2017-11-29 15:00:11 +02:00
parent cd3674bdc4
commit 508b3130d4
2 changed files with 1 additions and 2 deletions

View file

@ -507,8 +507,6 @@
android:paddingLeft="@dimen/context_menu_button_padding_x"
android:paddingRight="@dimen/context_menu_button_padding_x"
android:gravity="end|center_vertical"
tools:drawableEnd="@drawable/map_directions"
android:drawablePadding="@dimen/context_menu_padding_margin_medium"
android:textColor="?attr/contextMenuButtonColor"
android:textSize="@dimen/default_desc_text_size"
android:text="@string/get_directions"/>

View file

@ -462,6 +462,7 @@ public class MapContextMenuFragment extends BaseOsmAndFragment implements Downlo
Button directionsButton = (Button) view.findViewById(R.id.context_menu_directions_button);
Drawable drawable = getIcon(R.drawable.map_directions, nightMode ? R.color.osmand_orange : R.color.map_widget_blue);
directionsButton.setCompoundDrawablesWithIntrinsicBounds(null, null, drawable, null);
directionsButton.setCompoundDrawablePadding(dpToPx(8));
directionsButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {