/[emacs]/emacs/src/w32fns.c
ViewVC logotype

Diff of /emacs/src/w32fns.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.123.2.7 by jasonr, Sun Jan 20 17:00:59 2002 UTC revision 1.123.2.8 by jasonr, Thu Jan 24 20:20:36 2002 UTC
# Line 4101  w32_wnd_proc (hwnd, msg, wParam, lParam) Line 4101  w32_wnd_proc (hwnd, msg, wParam, lParam)
4101        {        {
4102          PAINTSTRUCT paintStruct;          PAINTSTRUCT paintStruct;
4103          RECT update_rect;          RECT update_rect;
4104            bzero (&update_rect, sizeof (update_rect));
4105    
4106          f = x_window_to_frame (dpyinfo, hwnd);          f = x_window_to_frame (dpyinfo, hwnd);
4107          if (f == 0)          if (f == 0)
# Line 4112  w32_wnd_proc (hwnd, msg, wParam, lParam) Line 4113  w32_wnd_proc (hwnd, msg, wParam, lParam)
4113          /* MSDN Docs say not to call BeginPaint if GetUpdateRect          /* MSDN Docs say not to call BeginPaint if GetUpdateRect
4114             fails.  Apparently this can happen under some             fails.  Apparently this can happen under some
4115             circumstances.  */             circumstances.  */
4116          if (!w32_strict_painting || GetUpdateRect (hwnd, &update_rect, FALSE))          if (GetUpdateRect (hwnd, &update_rect, FALSE) || !w32_strict_painting)
4117            {            {
4118              enter_crit ();              enter_crit ();
4119              BeginPaint (hwnd, &paintStruct);              BeginPaint (hwnd, &paintStruct);
4120    
4121              if (w32_strict_painting)              /* The rectangles returned by GetUpdateRect and BeginPaint
4122                /* The rectangles returned by GetUpdateRect and BeginPaint                 do not always match.  Play it safe by assuming both areas
4123                   do not always match.  GetUpdateRect seems to be the                 are invalid.  */
4124                   more reliable of the two.  */              UnionRect (&(wmsg.rect), &update_rect, &(paintStruct.rcPaint));
               wmsg.rect = update_rect;  
             else  
               wmsg.rect = paintStruct.rcPaint;  
4125    
4126  #if defined (W32_DEBUG_DISPLAY)  #if defined (W32_DEBUG_DISPLAY)
4127              DebPrint (("WM_PAINT (frame %p): painting %d,%d-%d,%d\n",              DebPrint (("WM_PAINT (frame %p): painting %d,%d-%d,%d\n",

Legend:
Removed from v.1.123.2.7  
changed lines
  Added in v.1.123.2.8

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26