home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / pwrgu2.zip / POWERGU2.EXE / CANVAS / MCLUNCH / PUSHBTNS.HPP < prev   
Text File  |  1995-07-25  |  1KB  |  49 lines

  1. #ifndef _PUSHBTNS_
  2. #define _PUSHBTNS_
  3. //************************************************************
  4. // Canvas  - IMultiCellCanvas Implementation of Lunch Dialog
  5. //
  6. // Copyright (C) 1994, Law, Leong, Love, Olson, Tsuji.
  7. // All Rights Reserved.
  8. //************************************************************
  9. #include <ipushbut.hpp>
  10. #include <isetcv.hpp>
  11. #include <isysmenu.hpp>
  12.  
  13. class MyStandardPushButtons : public ISetCanvas {
  14. public:
  15.   MyStandardPushButtons ( unsigned long id,
  16.                           IWindow*      parentAndOwner )
  17.     : ISetCanvas( id, parentAndOwner, parentAndOwner ),
  18.       ok( 1, this, this ),
  19.       cancel( ISystemMenu::idClose, this, this ),
  20.       help( 10, this, this )
  21.   {
  22.     (*this)
  23.      .setMargin( ISize() )
  24.      .setPackType( ISetCanvas::expanded );
  25.                         // Make all buttons the same size.
  26.     ok
  27.      .enableDefault()
  28.      .setText( "OK" )
  29.      .enableTabStop()
  30.      .enableGroup();
  31.     cancel
  32.      .enableSystemCommand()  // For ISystemMenu::idClose.
  33.      .setText( "Cancel" );
  34.     help
  35.      .enableHelp()
  36.      .disableMouseClickFocus()
  37.      .setText( "Help" );
  38.   }
  39. private:
  40. IPushButton
  41.   ok,
  42.   cancel,
  43.   help;
  44. MyStandardPushButtons ( const MyStandardPushButtons&);
  45. MyStandardPushButtons& operator= ( const MyStandardPushButtons&);
  46. };
  47.  
  48. #endif // _PUSHBTNS_
  49.