blob: f8541188f53794798d18d173f27afb9f6f9137f0 [file] [log] [blame]
Sunny Goyal1d0b0932015-03-20 18:51:38 -07001package com.android.launcher3.base;
2
3import android.app.Activity;
4import android.content.Context;
5
6/**
7 * A wrapper over {@link Activity} which allows to override some methods.
8 * The base implementation can change from an Activity to a Fragment (or any other custom
9 * implementation), Callers should not assume that the base class extends Context, instead use
10 * either {@link #getContext} or {@link #getActivity}
11 */
12public class BaseActivity extends Activity {
13
14 public Context getContext() {
15 return this;
16 }
17
18 public Activity getActivity() {
19 return this;
20 }
21}