Differential dijet cross sections have been measured with the ZEUS detector for photoproduction events in which the hadronic final state containing the jets is separated with respect to the outgoing proton direction by a large rapidity gap. The cross section has been measured as a function of the fraction of the photon (ϰγOBS) and pomeron (βOBS) momentum participating in the production of the dijet system. The observed ϰγOBS dependence shows evidence for the presence of a resolved- as well as a direct-photon component. The measured cross section da/dβOBS increases as βOBS increases indicating that there is a sizeable contribution to dijet production from those events in which a large fraction of the pomeron momentum participates in the hard scattering. These cross sections and the ZEUS measurements of the diffractive structure function can be described by calculations based on parton densities in the pomeron which evolve according to the QCD evolution equations and include a substantial hard momentum component of gluons in the pomeron.