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.app.Activity; | |
import android.content.Context; | |
import android.hardware.display.DisplayManager; | |
import android.os.Bundle; | |
import android.view.Display; | |
/** | |
* A base activity for watch faces that have callbacks for the various screen states (dim, awake, and off) | |
* as well as a callback for when the watch face is removed. | |
* <p/> |
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 ExampleActivity extends Activity implements WatchFaceLifecycle.Listener { | |
@Override | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
setContentView(R.layout.activity_my_layout); | |
WatchFaceLifecycle.attach(this, savedInstanceState, this); | |
} | |
@Override |
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
package android.app; | |
import android.content.Context; | |
import android.graphics.Matrix; | |
import android.graphics.Rect; | |
import android.graphics.RectF; | |
import android.os.Bundle; | |
import android.os.Handler; | |
import android.os.Parcelable; | |
import android.os.ResultReceiver; |
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
#!/bin/sh | |
LEVEL=3 | |
ISCHARGING=false | |
while [ 1=1 ] | |
do | |
adb shell screencap -p | sed 's/\r$//' > screen${LEVEL}.png |
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
package com.companionfree.tracker.bjj.util; | |
import android.animation.Animator; | |
import android.animation.ObjectAnimator; | |
import android.support.v7.widget.RecyclerView; | |
import android.view.ViewGroup; | |
import android.view.animation.AccelerateInterpolator; | |
import android.view.animation.DecelerateInterpolator; | |
import com.getbase.floatingactionbutton.FloatingActionButton; |
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
package mypackage.presentation.utils.view; | |
import android.os.Bundle; | |
import android.os.Parcelable; | |
import android.support.annotation.NonNull; | |
import android.support.annotation.Nullable; | |
import android.util.SparseArray; | |
import android.view.ViewGroup; | |
public class ChildrenViewStateHelper { |
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
@RunWith(Enclosed.class) | |
public class WorkflowStateMachineTest { | |
@RunWith(Parameterized.class) | |
public static class ParameterizedTests { | |
@Parameter public ISBatchType mTestBatchType; // first data value (0) is default |
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 MyFragment { | |
boolean loaded; | |
private void maybeLoad() { | |
if (!loaded && getUserVisibleHint()) { | |
loaded = true; | |
loadMyData(); | |
} | |
} | |
@Override |
OlderNewer