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.app.PendingIntent; | |
| import android.app.RecoverableSecurityException; | |
| import android.content.ContentResolver; | |
| import android.content.ContentValues; | |
| import android.content.Context; | |
| import android.content.IntentSender; | |
| import android.database.Cursor; | |
| import android.net.Uri; | |
| import android.os.Build; | |
| import android.provider.MediaStore; |
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
| class Analytics { | |
| private var startSessionTimestamp: Long = -1 | |
| private val reporters = mutableListOf<AnalyticsReporter>() | |
| fun addReporter(reporter: AnalyticsReporter) { | |
| reporters.add(reporter) | |
| } | |
| fun startSession() { | |
| startSessionTimestamp = Date().time |
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
| == Adb Server | |
| adb kill-server | |
| adb start-server | |
| == Adb Reboot | |
| adb reboot | |
| adb reboot recovery | |
| adb reboot-bootloader | |
| == Shell |
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
| package com.github.irshulx.glitchtext; | |
| import android.content.Context; | |
| import android.content.res.TypedArray; | |
| import android.graphics.Color; | |
| import android.text.TextUtils; | |
| import android.util.AttributeSet; | |
| import android.util.TypedValue; | |
| import android.view.Gravity; | |
| import android.view.View; |
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
| package com.grok.notes.util; | |
| import android.app.Activity; | |
| import android.os.AsyncTask; | |
| import android.util.Log; | |
| import java.util.concurrent.ExecutionException; | |
| import java.util.concurrent.TimeUnit; | |
| import java.util.concurrent.TimeoutException; |
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
| /** | |
| * Implementation of {@link OnClickListener} that ignores subsequent clicks that happen too quickly after the first one.<br/> | |
| * To use this class, implement {@link #onSingleClick(View)} instead of {@link OnClickListener#onClick(View)}. | |
| */ | |
| public abstract class OnSingleClickListener implements OnClickListener { | |
| private static final String TAG = OnSingleClickListener.class.getSimpleName(); | |
| private static final long MIN_DELAY_MS = 500; | |
| private long mLastClickTime; |
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 RealPathUtil { | |
| public static String getRealPath(Context context, Uri fileUri) { | |
| String realPath; | |
| // SDK < API11 | |
| if (Build.VERSION.SDK_INT < 11) { | |
| realPath = RealPathUtil.getRealPathFromURI_BelowAPI11(context, fileUri); | |
| } | |
| // SDK >= 11 && SDK < 19 | |
| else if (Build.VERSION.SDK_INT < 19) { |
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
| package com.gabesechan.android.reusable.receivers; | |
| import java.util.Date; | |
| import android.content.BroadcastReceiver; | |
| import android.content.Context; | |
| import android.content.Intent; | |
| import android.telephony.TelephonyManager; | |
| public abstract class PhonecallReceiver extends BroadcastReceiver { |
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
| //activity.xml | |
| <SeekBar | |
| android:layout_width="match_parent" | |
| android:layout_height="wrap_content" | |
| android:id="@+id/sb_progress" | |
| android:progressDrawable="@drawable/custom_seek_bar" | |
| android:paddingLeft="0dp" | |
| android:paddingRight="0dp" | |
| android:minHeight="8dip"//important! | |
| android:maxHeight="8dip"//important! |
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.annotation.TargetApi; | |
| import android.content.Context; | |
| import android.content.res.Configuration; | |
| import android.graphics.Bitmap; | |
| import android.graphics.Canvas; | |
| import android.graphics.Matrix; | |
| import android.graphics.PointF; | |
| import android.graphics.RectF; | |
| import android.graphics.drawable.Drawable; | |
| import android.net.Uri; |
NewerOlder