diff options
author | alexzatsepin <az@mapswithme.com> | 2016-12-14 12:41:32 +0300 |
---|---|---|
committer | alexzatsepin <az@mapswithme.com> | 2016-12-14 12:41:32 +0300 |
commit | 09c3343d9cfc77f4bd575fc97460fc113a3d40a4 (patch) | |
tree | da0cb42ff6695a3aa6d185f5760f7d1812c64765 /android | |
parent | 2d3229d6ed4f46dc3e04d609426461484d2e911d (diff) |
[android] Added hidding the banner icon if icon url is empty
Diffstat (limited to 'android')
-rw-r--r-- | android/src/com/mapswithme/maps/widget/placepage/BannerController.java | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/android/src/com/mapswithme/maps/widget/placepage/BannerController.java b/android/src/com/mapswithme/maps/widget/placepage/BannerController.java index dc8a020ba2..6f715185ec 100644 --- a/android/src/com/mapswithme/maps/widget/placepage/BannerController.java +++ b/android/src/com/mapswithme/maps/widget/placepage/BannerController.java @@ -179,9 +179,17 @@ final class BannerController implements View.OnClickListener private void loadIcon(@NonNull Banner banner) { - if (mIcon == null || TextUtils.isEmpty(banner.getIconUrl())) + if (mIcon == null) return; + if (TextUtils.isEmpty(banner.getIconUrl())) + { + UiUtils.hide(mIcon); + return; + } + + UiUtils.show(mIcon); + Glide.with(mIcon.getContext()) .load(banner.getIconUrl()) .centerCrop() |