Skip to content

Instantly share code, notes, and snippets.

View sheerazam's full-sized avatar

Sheeraz Ahmed Memon sheerazam

  • Constellation1 USA (Remote)
  • Pakistan
View GitHub Profile
@sheerazam
sheerazam / ScrollAwareFABBehavior.java
Last active October 19, 2016 12:09
Creating Scroll Aware Fab
public class ScrollAwareFABBehavior extends FloatingActionButton.Behavior {
private static final Interpolator INTERPOLATOR = new FastOutSlowInInterpolator();
private boolean mIsAnimatingOut = false;
public ScrollAwareFABBehavior(Context context, AttributeSet attrs) {
super();
}
@Override
public boolean onStartNestedScroll(final CoordinatorLayout coordinatorLayout, final FloatingActionButton child,
@sheerazam
sheerazam / MyApplication..java
Created September 28, 2016 14:06
CrashLytics Setup
//Crashlytics
Fabric.with(this, new Crashlytics());
@sheerazam
sheerazam / AndroidMenifest.xml
Last active September 28, 2016 13:31
Active Android Setup
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="retaillogics.activeandroidsample">
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/AppTheme"
@sheerazam
sheerazam / Memory Leaks Webview
Last active August 9, 2016 07:05
Avoiding Memory Leaks
http://stackoverflow.com/questions/3130654/memory-leak-in-webview
@sheerazam
sheerazam / splash screen.txt
Created July 25, 2016 06:54
Splash Screen Prerequisites
https://www.bignerdranch.com/blog/splash-screens-the-right-way/
http://szagurskii.com/blog/how-to-load-heavy-libraries-on-splash-screen/?utm_source=Android+Weekly&utm_campaign=644e634e1a-Android_Weekly_215&utm_medium=email&utm_term=0_4eb677ad19-644e634e1a-337989413
@sheerazam
sheerazam / PhonesListRecyclerAdapter.java
Last active May 3, 2016 09:33
Recycler View Adapter Sample....
public class PhonesListRecyclerAdapter extends RecyclerView.Adapter<PhonesListRecyclerAdapter.ViewHolder> {
private static final String TAG = PhonesListRecyclerAdapter.class.getSimpleName();
private List<PhoneNumber> mItems;
OnClickListener onClickListener;
public interface OnClickListener{
void onPhoneNumberClick(int position);
}
@sheerazam
sheerazam / cloudmassaging
Created April 11, 2016 09:31
Google Cloud Massaging
Step1: http://hmkcode.com/android-google-cloud-messaging-tutorial/
Step2: Send Push Message
https://github.com/mattg888/GCM-PHP-Server-Push-Message
Step 3: Install Xmpp
<?xml version="1.0" encoding="utf-8"?>
<!-- The important thing to note here is the added fitSystemWindows -->
<android.support.v4.widget.DrawerLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/my_drawer_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
>
@sheerazam
sheerazam / maputils
Created April 11, 2016 09:28
Android Map Utils
https://github.com/googlemaps/android-maps-utils
https://developers.google.com/maps/documentation/android/map?hl=pl#using_xml_attributes
@sheerazam
sheerazam / Google Analytics Sdk
Created April 11, 2016 09:28
Google Analytics Sdk
https://developers.google.com/analytics/devguides/collection/android/v4/