getSupportFragmentManager()defined only for the class FragmentActivity, not for Context. Therefore, the compiler cannot resolve the call if you try to call it on an object of type Context.
, . , FragmentActivity Context. . FragmentActivity - , FragmentActivity , Context.
, :
if (getContext() instanceof FragmentActivity) {
FragmentActivity activity = (FragmentActivity(getContext()));
FragmentTransaction t = activity.getSupportFragmentManager().beginTransaction();
}