jenkins-bot has submitted this change and it was merged.

Change subject: Hygiene: move FeaturedImageCardView callback
......................................................................


Hygiene: move FeaturedImageCardView callback

Encapsulate FeaturedImageCardView's callback as
FeaturedImageCardView.Callback.

Change-Id: Ideeed05abecb0de2b662a02d9d65de32aad10558
---
M app/src/main/java/org/wikipedia/feed/image/FeaturedImageCardView.java
M app/src/main/java/org/wikipedia/feed/view/FeedViewCallback.java
2 files changed, 8 insertions(+), 6 deletions(-)

Approvals:
  Dbrant: Looks good to me, approved
  jenkins-bot: Verified



diff --git 
a/app/src/main/java/org/wikipedia/feed/image/FeaturedImageCardView.java 
b/app/src/main/java/org/wikipedia/feed/image/FeaturedImageCardView.java
index e233f4d..567b87c 100644
--- a/app/src/main/java/org/wikipedia/feed/image/FeaturedImageCardView.java
+++ b/app/src/main/java/org/wikipedia/feed/image/FeaturedImageCardView.java
@@ -21,6 +21,12 @@
 
 public class FeaturedImageCardView extends 
DefaultFeedCardView<FeaturedImageCard>
         implements ItemTouchHelperSwipeAdapter.SwipeableView {
+    public interface Callback {
+        void onShareImage(@NonNull FeaturedImageCard card);
+        void onDownloadImage(@NonNull FeaturedImage image);
+        void onFeaturedImageSelected(@NonNull FeaturedImageCard card);
+    }
+
     @BindView(R.id.view_featured_image_card_header) View headerView;
     @BindView(R.id.view_featured_image_card_footer) View footerView;
     @BindView(R.id.view_featured_image_card_image) FaceAndColorDetectImageView 
imageView;
diff --git a/app/src/main/java/org/wikipedia/feed/view/FeedViewCallback.java 
b/app/src/main/java/org/wikipedia/feed/view/FeedViewCallback.java
index fbb2fdb..f29a75a 100644
--- a/app/src/main/java/org/wikipedia/feed/view/FeedViewCallback.java
+++ b/app/src/main/java/org/wikipedia/feed/view/FeedViewCallback.java
@@ -2,17 +2,13 @@
 
 import android.support.annotation.NonNull;
 
-import org.wikipedia.feed.image.FeaturedImage;
-import org.wikipedia.feed.image.FeaturedImageCard;
+import org.wikipedia.feed.image.FeaturedImageCardView;
 import org.wikipedia.feed.news.NewsItemCard;
 import org.wikipedia.views.ItemTouchHelperSwipeAdapter;
 
 public interface FeedViewCallback extends ItemTouchHelperSwipeAdapter.Callback,
-        PageTitleListCardItemView.Callback, CardHeaderView.Callback {
+        PageTitleListCardItemView.Callback, CardHeaderView.Callback, 
FeaturedImageCardView.Callback {
     void onSearchRequested();
     void onVoiceSearchRequested();
     void onNewsItemSelected(@NonNull NewsItemCard card);
-    void onShareImage(@NonNull FeaturedImageCard card);
-    void onDownloadImage(@NonNull FeaturedImage image);
-    void onFeaturedImageSelected(@NonNull FeaturedImageCard card);
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/312144
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ideeed05abecb0de2b662a02d9d65de32aad10558
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Niedzielski <sniedziel...@wikimedia.org>
Gerrit-Reviewer: BearND <bsitzm...@wikimedia.org>
Gerrit-Reviewer: Brion VIBBER <br...@wikimedia.org>
Gerrit-Reviewer: Dbrant <dbr...@wikimedia.org>
Gerrit-Reviewer: Mholloway <mhollo...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to