home *** CD-ROM | disk | FTP | other *** search
/ Power GUI Programming with VisualAge C++ / powergui.iso / powergui / cnr / minicnr / minicnr.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  1996-10-29  |  1018 b   |  45 lines

  1. //************************************************************
  2. // Container Control - Mini-icon Container
  3. //
  4. // Copyright (C) 1994, Law, Leong, Love, Olson, Tsuji.
  5. // Copyright (c) 1997 John Wiley & Sons, Inc. 
  6. // All Rights Reserved.
  7. //************************************************************
  8.  
  9. #include <iframe.hpp>
  10. #include <icnrctl.hpp>
  11. #include <iapp.hpp>
  12. // #include "cnrmini.hpp"
  13. #include "minicnr.h"
  14.  
  15. void main ()
  16. {
  17.  
  18. IFrameWindow cnrFrame("Mini-Icon Container");
  19. cnrFrame.sizeTo(ISize(200,200));
  20.  
  21. IContainerControl cnr(0x101,
  22.                       &cnrFrame,
  23.                       &cnrFrame);
  24.  
  25. // Put container in client area.
  26. cnrFrame.setClient(&cnr);
  27.  
  28. // Create an object.
  29. IContainerObject* folder = new
  30.             IContainerObject(IString("Folder "),
  31.             ICON_FOLDER);
  32. cnr.addObject(folder);
  33.  
  34. cnr.arrangeIconView();
  35.  
  36. // Show Icon view.
  37. cnr.showIconView();
  38. cnr.showMiniIcons();
  39.  
  40. cnrFrame.show();
  41. cnrFrame.setFocus();
  42.  
  43. IApplication::current().run();
  44. }
  45.