changeset 2359:707836e00e5e

Mac: setNeedsDisplay:YES needs to be on the main thread... So move dw_render_redraw() into the thread safety system.
author bsmith@81767d24-ef19-dc11-ae90-00e081727c95
date Tue, 09 Mar 2021 13:14:15 +0000
parents 314d417e55c4
children 98d0873d9c05
files mac/dw.m
diffstat 1 files changed, 7 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mac/dw.m	Mon Mar 08 23:50:57 2021 +0000
+++ b/mac/dw.m	Tue Mar 09 13:14:15 2021 +0000
@@ -6695,11 +6695,16 @@
  * Parameters:
  *       handle: A handle to a render widget to be redrawn.
  */
-void API dw_render_redraw(HWND handle)
-{
+DW_FUNCTION_DEFINITION(dw_render_redraw, void, HWND handle)
+DW_FUNCTION_ADD_PARAM1(handle)
+DW_FUNCTION_NO_RETURN(dw_render_redraw)
+DW_FUNCTION_RESTORE_PARAM1(handle, HWND)
+{
+    DW_FUNCTION_INIT;
     DWRender *render = (DWRender *)handle;
 
     [render setNeedsDisplay:YES];
+    DW_FUNCTION_RETURN_NOTHING;
 }
 
 /* Sets the current foreground drawing color.