diff options
| author | Manolo Gouy <Manolo> | 2015-08-07 12:55:56 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2015-08-07 12:55:56 +0000 |
| commit | cc36ab53b327b1a05edba006dcb581815fbdd08f (patch) | |
| tree | 2393b9c37db87a36461470c264df104a5ec58f0d /src/Fl_Window.cxx | |
| parent | 9a38c24d638023059db9059c3805f0f62b455dbd (diff) | |
- Implement Fl_Window::wait_for_expose() for Mac OS:
The -[NSWindow makeKeyAndOrderFront:] message used to make the window appear on the screen,
but, starting with 10.10 (approximately), this changed, and it became necessary to query for events
for a new window to appear on the screen. With 10.11 two event messages are needed.
The solution is therefore to implement Fl_Window::wait_for_expose().
- Calling NSDisableScreenUpdates()()/NSEnableScreenUpdates() before and after window updates
greatly accelerates multi-window update operations.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10826 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Window.cxx')
| -rw-r--r-- | src/Fl_Window.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Fl_Window.cxx b/src/Fl_Window.cxx index b4d3c621f..50bc65e94 100644 --- a/src/Fl_Window.cxx +++ b/src/Fl_Window.cxx @@ -462,9 +462,13 @@ void Fl_Window::free_icons() { void Fl_Window::wait_for_expose() { if (!shown()) return; +#ifdef __APPLE__ + Fl_X::do_wait_for_expose(); +#else while (!i || i->wait_for_expose) { Fl::wait(); } +#endif } // |
