diff --git a/OsmAnd/res/layout/fragment_wikivoyage_show_images_first_time.xml b/OsmAnd/res/layout/fragment_wikivoyage_show_images_first_time.xml index 88a886d390..289b629b43 100644 --- a/OsmAnd/res/layout/fragment_wikivoyage_show_images_first_time.xml +++ b/OsmAnd/res/layout/fragment_wikivoyage_show_images_first_time.xml @@ -7,6 +7,17 @@ android:background="?attr/bottom_menu_view_bg" android:orientation="vertical"> + + + + + + + - - - - - - + tools:ignore="UnusedAttribute" + tools:text="@string/shared_string_do" /> diff --git a/OsmAnd/res/layout/map_marker_item_header.xml b/OsmAnd/res/layout/map_marker_item_header.xml index 54e4da7a27..7a2144a243 100644 --- a/OsmAnd/res/layout/map_marker_item_header.xml +++ b/OsmAnd/res/layout/map_marker_item_header.xml @@ -54,6 +54,7 @@ android:layout_height="0dp" android:layout_weight="1" android:background="?attr/bg_color" + android:visibility="gone" android:orientation="vertical"> contentHeight) { + contentView.getLayoutParams().height = contentHeight; + contentView.requestLayout(); + } + ViewTreeObserver obs = mainView.getViewTreeObserver(); + if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN) { + obs.removeOnGlobalLayoutListener(this); + } else { + obs.removeGlobalOnLayoutListener(this); + } + } + }); + } + } + + private int getContentHeight(int availableScreenHeight) { + return availableScreenHeight + - AndroidUtils.dpToPx(getContext(), 1) // divider height + - getResources().getDimensionPixelSize(R.dimen.bottom_sheet_descr_height); + } } diff --git a/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java b/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java index ff175e352f..6ea8b42344 100644 --- a/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java +++ b/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java @@ -263,7 +263,7 @@ public class WikivoyageArticleDialogFragment extends WikivoyageBaseDialogFragmen public void onResume() { super.onResume(); OsmandSettings settings = getMyApplication().getSettings(); - if (!settings.WIKIVOYAGE_SHOW_IMAGES_ASKED.get()) { +// if (!settings.WIKIVOYAGE_SHOW_IMAGES_ASKED.get()) { FragmentActivity activity = getActivity(); FragmentManager fm = getFragmentManager(); if (activity != null && fm != null) { @@ -272,7 +272,7 @@ public class WikivoyageArticleDialogFragment extends WikivoyageBaseDialogFragmen fragment.show(fm, WikivoyageShowPicturesDialogFragment.TAG); settings.WIKIVOYAGE_SHOW_IMAGES_ASKED.set(true); } - } +// } } @Override