Category : OS/2 Files
Archive   : SRCDEMO.ZIP
Filename : CHILDWP.C

 
Output of file : CHILDWP.C contained in archive : SRCDEMO.ZIP
//***
//*** Name: ChildWP.C
//***
//*** Description: Child window's window procedure.
//***
//*** Calling format: MRESULT EXPENTRY CHILDWndProc(HWND hwnd,
//*** USHORT msg,
//*** MPARAM mp1,
//*** MPARAM mp2);
//***
//*** Inputs: hwnd - Handle to window procedure.
//*** msg - Message identifier.
//*** mp1 - Message parameter 1.
//*** mp2 - Message parameter 2.
//***
//*** Outputs: *NONE*
//***


//*** Include files - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

#include "infinity.h"


//*** Main program -------------------------------------------------------------

MRESULT EXPENTRY CHILDWNDPROC(HWND hwnd,USHORT msg,MPARAM mp1, MPARAM mp2)
{
HPS hps;
RECTL rcl;

switch(msg)
{
case WM_PAINT:
hps = WinBeginPaint(hwnd,NULL,NULL);
WinQueryWindowRect(hwnd,&rcl);
WinDrawText(hps,-1,WinQueryWindowPtr(hwnd,QWL_USER),&rcl,
CLR_NEUTRAL,CLR_BACKGROUND,
DT_CENTER | DT_VCENTER | DT_ERASERECT);
WinEndPaint(hps);
return 0;

case WM_CLOSE:
WinDestroyWindow(WinQueryWindow(hwnd,QW_PARENT,FALSE));
return 0;
}

//*** Unknown message - use default processing ---------------------------------

return WinDefWindowProc(hwnd,msg,mp1,mp2);
}


  3 Responses to “Category : OS/2 Files
Archive   : SRCDEMO.ZIP
Filename : CHILDWP.C

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/