Check 'grabcursorenabled' option value before setting the grab cursor

I needed to disable this grab cursor, and changing the grabcursorenabled option seemed to have no effect. This change seems to fix it for me.