get activity in adapter code example
Example: access activity method from adapter
if (mContext instanceof YourActivityName) {
((YourActivityName)mContext).yourDesiredMethod();
if (mContext instanceof YourActivityName) {
((YourActivityName)mContext).yourDesiredMethod();