home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 11 Util / 11-Util.zip / memsz331.zip / Source.zip / ABOUT.CPP next >
Text File  |  1995-05-25  |  2KB  |  43 lines

  1. /****************************************************************** ABOUT.CPP
  2.  *                                                                          *
  3.  *                        Generic "About" Dialog                            *
  4.  *                                                                          *
  5.  ****************************************************************************/
  6.  
  7. #define INCL_BASE
  8. #define INCL_PM
  9. #include <os2.h>
  10.  
  11. #include "About.h"
  12.  
  13.  
  14. /****************************************************************************
  15.  *                                                                          *
  16.  *      "About" Dialog Processor                                            *
  17.  *                                                                          *
  18.  ****************************************************************************/
  19.  
  20. extern MRESULT EXPENTRY AboutProcessor ( HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2 ) {
  21.  
  22.    switch ( msg ) {
  23.  
  24.       case WM_INITDLG: {
  25.          WinAssociateHelpInstance ( WinQueryHelpInstance(WinQueryWindow(hwnd,QW_OWNER)), hwnd ) ;
  26.          return ( 0 ) ; }
  27.  
  28.       case WM_COMMAND: {
  29.          switch ( SHORT1FROMMP(mp1) ) {
  30.             case DID_OK:
  31.                WinDismissDlg ( hwnd, TRUE ) ;
  32.                break ;
  33.             case DID_CANCEL:
  34.                WinDismissDlg ( hwnd, FALSE ) ;
  35.                break ;
  36.          } /* endswitch */
  37.          return ( 0 ) ; }
  38.  
  39.    } /* endswitch */
  40.  
  41.    return ( WinDefDlgProc ( hwnd, msg, mp1, mp2 ) ) ; 
  42. }
  43.