Created
February 5, 2018 15:29
-
-
Save iamBedant/86370ca54525c73c5544e944cfff7462 to your computer and use it in GitHub Desktop.
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
@Module | |
public class ActivityModule { | |
private Activity mActivity; | |
public ActivityModule(Activity activity) { | |
mActivity = activity; | |
} | |
@Provides | |
@ActivityContext | |
Context provideContext() { | |
return mActivity; | |
} | |
@Provides | |
Activity provideActivity() { | |
return mActivity; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment