  We study Dirac fermions in gapped graphene that are subjected to a magnetic
field and a potential barrier harmonically oscillating in time. The tunneling
modes inside the gap and the associated Goos-H\"anchen (GH) shifts are
analytically investigated. We show that the GH shifts in transmission for the
central band and the first two sidebands change sign at the Dirac points
$\epsilon+l\hbar\tilde{\omega}$ $(l=0,\pm 1)$. We also find that the GH shifts
can be either negative or positive and becomes zero at transmission resonances.
