Implements replace and show/hide fragment transaction patterns