1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-07-24 22:24:23 +00:00

Splits display update and draw functions.

On the Mac, draw is now called without an update for resizing events, and
anything else requested by AppKit. In all other cases — including from
the SDL version — both are called as if they were still a single function.
This commit is contained in:
Thomas Harte
2019-03-02 19:33:28 -05:00
parent 42d8d187b3
commit bee0d09877
9 changed files with 68 additions and 44 deletions

View File

@@ -776,7 +776,8 @@ int main(int argc, char *argv[]) {
// Display a new frame and wait for vsync.
updater.update();
scan_target.draw(true, int(window_width), int(window_height));
scan_target.update(int(window_width), int(window_height));
scan_target.draw(int(window_width), int(window_height));
if(activity_observer) activity_observer->draw();
SDL_GL_SwapWindow(window);
}