Blank the window at creation so that there is no initial flash of color changing, in case the background color is not black

Fixes #1404
This commit is contained in:
Kovid Goyal 2019-02-25 14:32:56 +05:30
parent c9446727d3
commit b7b1a1f1c6
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -599,6 +599,10 @@ create_os_window(PyObject UNUSED *self, PyObject *args) {
warned = true;
}
}
// blank the window once so that there is no initial flash of color
// changing, in case the background color is not black
blank_os_window(w);
swap_window_buffers(w);
return PyLong_FromUnsignedLongLong(w->id);
}