quartz: Fix crash when realizing GtkOffscreenWindow

GtkOffscreenWindow doesn't have a NSView or NSWindow, so return NULL if
passed one of those.

Closes: #379
2 jobs for 379-fix-quartz-offscreen-window-crash in 8 minutes and 11 seconds (queued for 1 minute and 5 seconds)