This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by feromakovi <feromakovi@gmail.com> on 12/10/16. | |
*/ | |
@UiThread | |
public final class FocusWatcher implements View.OnFocusChangeListener { | |
private final List<WeakReference<View>> mWatchedViews = new ArrayList<>(); | |
private WeakReference<View> mFallBackView; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class FilterPageTransformer implements ViewPager.PageTransformer { | |
public void transformPage(View view, float position) { | |
ImageView im = (ImageView) view; | |
int pageWidth = view.getWidth(); | |
if (position < -1) { // [-Infinity,-1) | |
// This page is way off-screen to the left. | |
im.setPadding(pageWidth, 0, 0, 0); |