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
import android.content.Context; | |
import android.content.res.TypedArray; | |
import android.graphics.Canvas; | |
import android.graphics.Rect; | |
import android.graphics.drawable.Drawable; | |
import android.support.v7.widget.LinearLayoutManager; | |
import android.support.v7.widget.RecyclerView; | |
import android.util.AttributeSet; | |
import android.view.View; |
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
<?xml version="1.0" encoding="utf-8"?> | |
<!-- | |
Google Material Design Color Palette for Android http://www.google.com/design/spec/style/color.html#color-ui-color-palette | |
Spreadsheet used to create this reosurce - http://bit.ly/mdcolor_spreadsheet | |
Link to this colors.xml resource file - http://bit.ly/mdcolorsxml | |
Harshad Kale | |
https://github.com/kalehv | |
[email protected] |
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 abstract class EndlessRecyclerViewScrollListener extends RecyclerView.OnScrollListener { | |
// The minimum amount of items to have below your current scroll position | |
// before loading more. | |
private int visibleThreshold = 5; | |
// The current offset index of data you have loaded | |
private int currentPage = 0; | |
// The total number of items in the dataset after the last load | |
private int previousTotalItemCount = 0; |
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
/** | |
* @author Pratik Butani | |
*/ | |
public class NetworkUtils extends BroadcastReceiver { | |
/** | |
* Context Variable | |
*/ | |
Context context; |
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
<?php | |
/** | |
* Created By : Pratik Butani | |
* Created Date : 24/10/2018 | |
*/ | |
// Database Connection | |
include "conn.php"; | |
// Get Records from Table | |
$sql = "SELECT * from fcm"; |
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
/** | |
* Main file for Time Picker. | |
*/ | |
public class TimePickerUniversal implements View.OnFocusChangeListener, TimePickerDialog.OnTimeSetListener, View.OnClickListener { | |
private EditText mEditText; | |
private Calendar mCalendar; | |
private SimpleDateFormat mFormat; | |
private boolean withAMPM; |
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 abstract class BaseActivity extends AppCompatActivity { | |
/** | |
* DataBinding Object | |
*/ | |
private ViewDataBinding mBindingObject; | |
/** | |
* Context common | |
*/ |
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 abstract class BaseFragment extends Fragment { | |
/** | |
* DataBinding Object | |
*/ | |
private ViewDataBinding mBindingObject; | |
/** | |
* Context common | |
*/ |
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 MyFirebaseMessagingService extends FirebaseMessagingService { | |
private static final String TAG = "MyFirebaseMessagingServ"; | |
private static int NOTIFICATION_ID = 1; | |
@Override | |
public void onMessageReceived(RemoteMessage remoteMessage) { | |
super.onMessageReceived(remoteMessage); | |
// Check if message contains a data payload. |
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 abstract class LocationHelperActivity extends AppCompatActivity { | |
private static final String TAG = "LocationHelperActivity"; | |
private static final int PERMISSION_REQUEST_CODE = 200; | |
public static final long INTERVAL = 1000 * 3 * 60; // 3 = 3 minutes | |
public static final long FASTEST_INTERVAL = 1000 * 60; // 60 = 60 seconds = 1 minutes | |
public String mCurrentLatitude = ""; | |
public String mCurrentLongitude = ""; |
OlderNewer