We investigate the magnetic hysteresis of a superconducting microstrip resonator with a high edge barrier. We measure the magnetic hysteresis while either sweeping a magnetic field or tuning the edge barrier by high microwave current. We show that the magnetic hysteresis of such a device is qualitatively different from that of one without an edge barrier and can be understood based on the generalized critical-state model. In particular, we propose and demonstrate a simple and intuitive method that relies on a plot of the quality factor versus the resonance frequency for revealing the physical processes behind those hysteretic behaviors. Based on this, we find that the interplay between the Meisser current and vortex pinning is essential for understanding the magnetic hysteresis of such a device.