home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / os / mswindo / programm / misc / 1696 < prev    next >
Encoding:
Text File  |  1992-09-08  |  1.1 KB  |  35 lines

  1. Newsgroups: comp.os.ms-windows.programmer.misc
  2. Path: sparky!uunet!psgrain!hippo!ucthpx!casper.cs.uct.ac.za!jholdern
  3. From: jholdern@casper.cs.uct.ac.za (J E Holderness)
  4. Subject: Minimized icon not displayed correctly
  5. Message-ID: <Bu5IyC.3oC@casper.cs.uct.ac.za>
  6. Organization: Computer Science Department, University of Cape Town
  7. Date: Sun, 6 Sep 1992 10:11:00 GMT
  8. Lines: 25
  9.  
  10. I've written a small application that uses a dialog box for its main
  11. window (don't know if that makes any difference). The problem is that when
  12. it is minimized, the icon doesn't display - it looks like its displaying
  13. the top left hand corner of the client area.
  14.  
  15. The icon does display properly when I use alt-tab to flip between tasks,
  16. and also when I move it (it shows up black and white as it should).
  17.  
  18. My GetWindowClass and GetClassName funcs look something like this:
  19.  
  20. LPSTR TMyWindow::GetClassName()
  21. {
  22.   return "MyWindow";
  23. }
  24.  
  25. void TMyWindow::GetWindowClass(WNDCLASS& AClass)
  26. {
  27.   TDialog::GetWindowClass(AClass);
  28.   AClass.hIcon = LoadIcon (GetModule()->hInstance, MAKEINTRESOURCE(MY_ICON));
  29. }
  30.  
  31. I am using Borland C OWL. Any ideas what I am doing wrong?
  32.  
  33. - jim
  34.  
  35.