This file contains hidden or 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
<html> | |
<body> | |
<h2>Privacy Policy</h2> | |
<p>[Individual or Company Name] built the [App Name] app as a [open source | free | freemium | ad-supported | commercial] app. This SERVICE is provided by [Individual or company name] [at no cost] and is intended | |
for use as is.</p> | |
<p>This page is used to inform website visitors regarding [my|our] policies with the collection, use, and | |
disclosure of Personal Information if anyone decided to use [my|our] Service.</p> | |
<p>If you choose to use [my|our] Service, then you agree to the collection and use of information in | |
relation with this policy. The Personal Information that [I|we] collect are used for providing and | |
improving the Service. [I|We] will not use or share your information with anyone except as described |
This file contains hidden or 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 CustomAnimationUtils { | |
public static void animateY(@NonNull View view, int startY, int endY, int duration) { | |
animateY(view, startY, endY, duration, new AccelerateDecelerateInterpolator()); | |
} | |
public static void animateY(@NonNull View view, int startY, int endY, int duration, | |
@NonNull Interpolator interpolator) { | |
view.clearAnimation(); | |
This file contains hidden or 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 CardsPagerTransformerBasic implements ViewPager.PageTransformer { | |
private int baseElevation; | |
private int raisingElevation; | |
private float smallerScale; | |
public CardsPagerTransformerBasic(int baseElevation, int raisingElevation, float smallerScale) { | |
this.baseElevation = baseElevation; | |
this.raisingElevation = raisingElevation; | |
this.smallerScale = smallerScale; |
This file contains hidden or 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 static Bitmap getBitmapFromView(View view) { | |
Bitmap bitmap = Bitmap.createBitmap(view.getWidth(), view.getHeight(), Bitmap.Config.ARGB_8888); | |
Canvas c = new Canvas(bitmap); | |
view.layout(view.getLeft(), view.getTop(), view.getRight(), view.getBottom()); | |
view.draw(c); | |
return bitamp; | |
} |
This file contains hidden or 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 interface AvailabilityChecker { | |
Observable<ValidationResult<String>> isEmailAvailable(@NonNull String email); | |
Observable<ValidationResult<String>> isUsernameAvailable(@NonNull String email); | |
ValidationResult<String> isEmailAvailableSync(@NonNull String email); | |
ValidationResult<String> isUsernameAvailableSync(@NonNull String email); | |
} |
This file contains hidden or 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 Jay Rambhia on 28/11/15. | |
*/ | |
public class HorizontalTwoTextView extends TextView { | |
private final String TAG = getClass().getSimpleName(); | |
private Layout mSubTextLayout; | |
private CharSequence mSubText; | |
private TextPaint mSubTextPaint; |
This file contains hidden or 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
<android.support.design.widget.CoordinatorLayout | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:tools="http://schemas.android.com/tools" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:id="@+id/main_content" | |
tools:context=".ContactsActivity"> | |
<android.support.design.widget.AppBarLayout |
This file contains hidden or 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
// LoaderCallback is just some callback that I use | |
private void fetchBitmap(String path, final LoaderCallback loaderCallback){ | |
// Retrofit call. | |
Observable<Response> responseObservable = loaderService.getImage(path); | |
// ObservableBitmap is a class that wraps Bitmap and has other fields like local_path, remote_path. | |
responseObservable.flatMap(new Func1<Response, Observable<ObservableBitmap>>() { |
This file contains hidden or 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
import android.content.Context; | |
import com.j256.ormlite.android.apptools.OpenHelperManager; | |
/** | |
* Created by Jay Rambhia on 05/04/15. | |
*/ | |
public class DatabaseManager { | |
private DatabaseHelper databaseHelper = null; |