--- q_a/samples/regions/regions.c 2018/08/09 18:29:33 1.1.1.2 +++ q_a/samples/regions/regions.c 2018/08/09 18:29:57 1.1.1.3 @@ -1,3 +1,14 @@ + +/******************************************************************************\ +* This is a part of the Microsoft Source Code Samples. +* Copyright (C) 1993 Microsoft Corporation. +* All rights reserved. +* This source code is only intended as a supplement to +* Microsoft Development Tools and/or WinHelp documentation. +* See these sources for detailed information regarding the +* Microsoft samples programs. +\******************************************************************************/ + /******************************************************************************\ * * PROGRAM: Regions.c @@ -11,7 +22,7 @@ * CreatePolyPolygonRgn() * CreateRectRgn() * FillRgn() -* #ifdef NOTIMPLEMENTED FrameRgn() #endif +* FrameRgn() * GetRgnBox() * InvertRgn() * OffsetRgn() @@ -45,10 +56,6 @@ * affect this region. When two regions are combined the * second region will be destroyed. * -* -* Microsoft Developer Support -* Copyright (c) 1992 Microsoft Corporation -* \******************************************************************************/ #include @@ -73,7 +80,7 @@ int WINAPI WinMain (HANDLE hInstance, HA { WNDCLASS wc; - wc.style = NULL; + wc.style = 0; wc.lpfnWndProc = (WNDPROC)MainWndProc; wc.cbClsExtra = 0; wc.cbWndExtra = 0; @@ -97,11 +104,11 @@ int WINAPI WinMain (HANDLE hInstance, HA WS_SYSMENU | WS_MINIMIZEBOX, CW_USEDEFAULT, CW_USEDEFAULT, 220, 280, NULL, NULL, hInstance, NULL))) - return (NULL); + return (0); ShowWindow (hwnd, nCmdShow); - while (GetMessage (&msg, NULL, NULL, NULL)) + while (GetMessage (&msg, NULL, 0,0)) { TranslateMessage (&msg); DispatchMessage (&msg); @@ -322,7 +329,7 @@ LRESULT CALLBACK MainWndProc (HWND hWnd, DialogBox (hInst, (LPCTSTR) "About", hWnd, (DLGPROC)AboutDlgProc); break; } - return (NULL); + return (0); case WM_LBUTTONDOWN: { @@ -354,7 +361,7 @@ LRESULT CALLBACK MainWndProc (HWND hWnd, EnableMenuItem (GetSubMenu (hMenu, 0), IDM_RECTINRGN, MF_DISABLED | MF_GRAYED | MF_BYCOMMAND); - return (NULL); + return (0); } case WM_MOUSEMOVE: @@ -366,7 +373,7 @@ LRESULT CALLBACK MainWndProc (HWND hWnd, TrackRect (ptr, TRECT_PAINT, hWnd, lParam); - return (NULL); + return (0); case WM_LBUTTONUP: @@ -390,7 +397,7 @@ LRESULT CALLBACK MainWndProc (HWND hWnd, MessageBeep (0); } - return (NULL); + return (0); case WM_PAINT: { @@ -434,12 +441,12 @@ LRESULT CALLBACK MainWndProc (HWND hWnd, } } EndPaint (hWnd, &ps); - return (NULL); + return (0); } case WM_DESTROY: - PostQuitMessage(NULL); - return (NULL); + PostQuitMessage(0); + return (0); } return (DefWindowProc(hWnd, message, wParam, lParam)); }