X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;f=glws_cocoa.mm;h=493cb4a58dc54b1c3af3e0a9da4243298d2b70a2;hb=79ae5703b55b13194e1dc50db7f5813d107e8806;hp=a35dcf506370d0d8215305572897b9576f8694ee;hpb=212718d6191b4a43c710a7979e566dbbb4123585;p=apitrace diff --git a/glws_cocoa.mm b/glws_cocoa.mm index a35dcf5..493cb4a 100644 --- a/glws_cocoa.mm +++ b/glws_cocoa.mm @@ -104,7 +104,9 @@ public: void resize(int w, int h) { - Drawable::resize(w, h); + if (w == width && h == height) { + return; + } [window setContentSize:NSMakeSize(w, h)]; @@ -114,13 +116,18 @@ public: [currentContext setView:[window contentView]]; [currentContext makeCurrentContext]; } + + Drawable::resize(w, h); } void show(void) { - if (!visible) { - // TODO - Drawable::show(); + if (visible) { + return; } + + // TODO + + Drawable::show(); } void swapBuffers(void) {