From d82f45f41fed7b46097be832be3e199bcd586fd1 Mon Sep 17 00:00:00 2001 From: PavelRatushny Date: Wed, 27 Dec 2017 12:54:17 +0200 Subject: [PATCH] Styling read full article button --- OsmAnd/res/layout/wikipedia_dialog_fragment.xml | 3 ++- OsmAnd/res/values-large/sizes.xml | 2 ++ OsmAnd/res/values/sizes.xml | 2 ++ .../osmand/plus/mapcontextmenu/WikipediaDialogFragment.java | 4 ++-- 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/OsmAnd/res/layout/wikipedia_dialog_fragment.xml b/OsmAnd/res/layout/wikipedia_dialog_fragment.xml index 0926fef2ba..9b37a95707 100644 --- a/OsmAnd/res/layout/wikipedia_dialog_fragment.xml +++ b/OsmAnd/res/layout/wikipedia_dialog_fragment.xml @@ -87,7 +87,8 @@ android:padding="@dimen/content_padding"/> - 78dp + 29dp + \ No newline at end of file diff --git a/OsmAnd/res/values/sizes.xml b/OsmAnd/res/values/sizes.xml index 8f73163ed6..4b9bdbe7da 100644 --- a/OsmAnd/res/values/sizes.xml +++ b/OsmAnd/res/values/sizes.xml @@ -247,4 +247,6 @@ 48dp 52dp + + 19dp \ No newline at end of file diff --git a/OsmAnd/src/net/osmand/plus/mapcontextmenu/WikipediaDialogFragment.java b/OsmAnd/src/net/osmand/plus/mapcontextmenu/WikipediaDialogFragment.java index 7e06f1ba27..8cc8337dbb 100644 --- a/OsmAnd/src/net/osmand/plus/mapcontextmenu/WikipediaDialogFragment.java +++ b/OsmAnd/src/net/osmand/plus/mapcontextmenu/WikipediaDialogFragment.java @@ -139,11 +139,11 @@ public class WikipediaDialogFragment extends DialogFragment { readFullArticleButton.setLayoutParams(params); readFullArticleButton.setBackgroundResource(darkMode ? R.drawable.bt_round_long_night : R.drawable.bt_round_long_day); readFullArticleButton.setTextColor(buttonColorStateList); - int paddingLeft = (int) getResources().getDimension(R.dimen.content_padding_small); + int paddingLeft = (int) getResources().getDimension(R.dimen.wikipedia_button_left_padding); int paddingRight = (int) getResources().getDimension(R.dimen.dialog_content_margin); readFullArticleButton.setPadding(paddingLeft, 0, paddingRight, 0); readFullArticleButton.setCompoundDrawablesWithIntrinsicBounds(getIcon(R.drawable.ic_world_globe_dark), null, null, null); - readFullArticleButton.setCompoundDrawablePadding(paddingLeft); + readFullArticleButton.setCompoundDrawablePadding((int) getResources().getDimension(R.dimen.content_padding_small)); final TextView selectLanguageTextView = mainView.findViewById(R.id.select_language_text_view); selectLanguageTextView.setTextColor(buttonColorStateList);