diff --git a/app/src/main/java/com/simplemobiletools/gallery/adapters/MyPagerAdapter.java b/app/src/main/java/com/simplemobiletools/gallery/adapters/MyPagerAdapter.java index 09aee6741..7f73710a5 100644 --- a/app/src/main/java/com/simplemobiletools/gallery/adapters/MyPagerAdapter.java +++ b/app/src/main/java/com/simplemobiletools/gallery/adapters/MyPagerAdapter.java @@ -33,10 +33,6 @@ public class MyPagerAdapter extends FragmentStatePagerAdapter { @Override public Fragment getItem(int position) { - if (fragment != null) { - fragment.fragmentHidden(); - } - final Medium medium = media.get(position); final Bundle bundle = new Bundle(); bundle.putSerializable(Constants.MEDIUM, medium); diff --git a/app/src/main/java/com/simplemobiletools/gallery/fragments/PhotoFragment.java b/app/src/main/java/com/simplemobiletools/gallery/fragments/PhotoFragment.java index ba7a43d62..90a3a760b 100644 --- a/app/src/main/java/com/simplemobiletools/gallery/fragments/PhotoFragment.java +++ b/app/src/main/java/com/simplemobiletools/gallery/fragments/PhotoFragment.java @@ -8,9 +8,9 @@ import android.view.ViewGroup; import com.davemorrissey.labs.subscaleview.ImageSource; import com.davemorrissey.labs.subscaleview.SubsamplingScaleImageView; import com.simplemobiletools.gallery.Constants; -import com.simplemobiletools.gallery.models.Medium; import com.simplemobiletools.gallery.R; import com.simplemobiletools.gallery.activities.ViewPagerActivity; +import com.simplemobiletools.gallery.models.Medium; public class PhotoFragment extends ViewPagerFragment implements View.OnClickListener { @@ -45,9 +45,4 @@ public class PhotoFragment extends ViewPagerFragment implements View.OnClickList public void itemDragged() { } - - @Override - public void fragmentHidden() { - - } } diff --git a/app/src/main/java/com/simplemobiletools/gallery/fragments/VideoFragment.java b/app/src/main/java/com/simplemobiletools/gallery/fragments/VideoFragment.java index 120b0db55..8493643b3 100644 --- a/app/src/main/java/com/simplemobiletools/gallery/fragments/VideoFragment.java +++ b/app/src/main/java/com/simplemobiletools/gallery/fragments/VideoFragment.java @@ -77,10 +77,6 @@ public class VideoFragment extends ViewPagerFragment pauseVideo(); } - public void fragmentHidden() { - cleanup(); - } - private void initTimeHolder(View view) { RelativeLayout timeHolder = (RelativeLayout) view.findViewById(R.id.video_time_holder); final Resources res = getResources(); diff --git a/app/src/main/java/com/simplemobiletools/gallery/fragments/ViewPagerFragment.java b/app/src/main/java/com/simplemobiletools/gallery/fragments/ViewPagerFragment.java index b16ee5525..53bf8c617 100644 --- a/app/src/main/java/com/simplemobiletools/gallery/fragments/ViewPagerFragment.java +++ b/app/src/main/java/com/simplemobiletools/gallery/fragments/ViewPagerFragment.java @@ -4,6 +4,4 @@ import android.support.v4.app.Fragment; public abstract class ViewPagerFragment extends Fragment { public abstract void itemDragged(); - - public abstract void fragmentHidden(); }