Skip to content

Instantly share code, notes, and snippets.

Saurabh Pant aqua30

View GitHub Profile
@aqua30
aqua30 / BaseActivity.java
Last active Sep 27, 2017
Hide the view binding using ButterKnife and Abstraction.
View BaseActivity.java
/**
* Created by Saurabh(aqua) on 21-03-2017.
*/
public abstract class BaseActivity extends AppCompatActivity implements LifecycleRegistryOwner {
private LifecycleRegistry lifecycleRegistry = new LifecycleRegistry(this);
private Unbinder unbinder;
@Override
View ConnectionLiveData.java
package test;
import android.arch.lifecycle.LiveData;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.net.ConnectivityManager;
import android.net.NetworkInfo;
View HideShowRecyclerParallaxActivity.java
/**
* Created by Saurabh(aqua) in 2017.
*/
public class HideShowRecyclerParallaxActivity extends BaseActivity {
/* view binding */
@BindView(R.id.recycler_view)RecyclerView recyclerView;
@BindView(R.id.parallax_image)ImageView parallaxImage;
@BindView(R.id.tv_heading)AppTextView heading;
@aqua30
aqua30 / RecyclerParallaxActivity.java
Created Sep 20, 2017
Parallax effect using RecyclerView in the most simple way using scroll listener of recycler view.
View RecyclerParallaxActivity.java
/**
* Created by Saurabh(aqua) in 2017.
*/
public class RecyclerParallaxActivity extends BaseActivity {
/* view binding */
@BindView(R.id.recycler_view)RecyclerView recyclerView;
@BindView(R.id.parallax_image)ImageView parallaxImage;
@aqua30
aqua30 / HideShowScrollParallaxActivity.java
Last active Sep 4, 2019
Show/Hide view on up/down scroll in android - Using ScrollView
View HideShowScrollParallaxActivity.java
/**
* Created by Saurabh(aqua) in 2017.
*/
public class ScrollActivity extends BaseActivity {
/* view binding */
@BindView(R.id.scrollView)ScrollView scrollView;
@BindView(R.id.parallax_image)ImageView parallaxImage;
@BindView(R.id.tv_perhour)TextView textView;
@aqua30
aqua30 / ScrollParallaxActivity.java
Last active Sep 20, 2017
Simplest ScrollView Parallax technique in Android. No library required and just with 4 lines of code, you can easily create parallax effect.
View ScrollParallaxActivity.java
/**
* Created by Saurabh(aqua) in 2017.
*/
public class ParallaxActivity extends BaseActivity {
/* view binding */
@BindView(R.id.scrollView)ScrollView scrollView;
@BindView(R.id.parallax_image)ImageView parallaxImage;
@BindView(R.id.tv_perhour)TextView textView;
You can’t perform that action at this time.