Skip to content

Instantly share code, notes, and snippets.

View petterh's full-sized avatar

Petter Hesselberg petterh

View GitHub Profile
petterh /
Last active June 30, 2020 09:34 — forked from alexjlockwood/
Sample usage of the "" class.
public class MainActivity extends Activity {
protected void onCreate(Bundle savedInstanceState) {
// Always register before calling into the super class.
getApplication().registerActivityLifecycleCallbacks(new MyActivityLifecycleCallbacks(this));