home *** CD-ROM | disk | FTP | other *** search
/ PC Pro 1995 October / PCPRO_OCT.ISO / code / program / sbsimple.txt
Encoding:
Text File  |  1995-08-08  |  537 b   |  19 lines

  1. void MyApp_OnMenuSelect (HWND hwnd, HMENU hmenu, int item, HMENU hmenuPopup, UINT flags)    
  2. {
  3.     BOOL fSimple;
  4.     char szBuff [256];
  5.  
  6.     fSimple = flags != 0xFFFF || hmenu != NULL; 
  7.  
  8.     // If menu is closing, set status bar back to normal
  9.  
  10.     SendMessage (hWndStatus, SB_SIMPLE, fSimple, 0);
  11.  
  12.     if (fSimple)
  13.     {
  14.         if (flags & MF_SEPARATOR) szBuff [0] = æ\0Æ;
  15.         else LoadString (hInstance, item, szBuff, sizeof (szBuff));
  16.         SendMessage (hWndStatus, SB_SETTEXT, 255, (LPARAM) szBuff);
  17.     }
  18. }
  19.