diff --git a/collects/mred/mred.ss b/collects/mred/mred.ss index 85246065..c8117d05 100644 --- a/collects/mred/mred.ss +++ b/collects/mred/mred.ss @@ -3670,9 +3670,18 @@ (sequence (let ([cwho '(constructor canvas)]) (check-container-parent cwho parent) - (check-style cwho #f '(border hscroll vscroll) style) - (check-container-ready cwho parent))) + (check-style cwho #f '(border hscroll vscroll gl) style) + (check-container-ready cwho parent) + (when (memq 'gl style) + (unless (eq? (system-type) 'windows) + (raise-mismatch-error (who->name cwho) + "the 'gl style flag is not supported on this platform: " + style))))) (public + [swap-gl-buffers (lambda () (send wx swap-buffers))] + [grab-gl-context (lambda () (send wx this-context-current))] + [restore-gl-context (lambda () (send wx previous-context-current))] + [accept-tab-focus (entry-point (case-lambda [() (send wx get-tab-focus)] diff --git a/collects/mred/private/kernel.ss b/collects/mred/private/kernel.ss index 4a6a8b53..b389dd52 100644 --- a/collects/mred/private/kernel.ss +++ b/collects/mred/private/kernel.ss @@ -333,6 +333,9 @@ on-size on-set-focus on-kill-focus + previous-context-current + this-context-current + swap-buffers on-scroll set-scroll-page set-scroll-range