home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / BC_502 / AWARE_H.PAK / DBNVGTR.H < prev    next >
Encoding:
C/C++ Source or Header  |  1997-05-06  |  4.1 KB  |  130 lines

  1. //--------------------------------------------------------
  2. // DBNVGTR.H generated from BDBCTL.VBX
  3. // Copyright (C) 1996 Borland International
  4. //--------------------------------------------------------
  5.  
  6. #if !defined(DBNAVIGATOR_H_)
  7. #define  DBNAVIGATOR_H_
  8.  
  9. #include <vdbt/dbcontrl.h>
  10.  
  11. //--------------------------------------------------------
  12. // TDBNavigator (VB3)
  13. //--------------------------------------------------------
  14.  
  15. class _DBAWARECLASS TDBNavigator : public TDBControl {
  16.   DBPMECLASS( TDBNavigator );
  17.  
  18.   // constructors
  19.   DECLARE_CONSTRUCTORS( TDBNavigator );
  20.  
  21.  
  22.   public:
  23.     // Properties
  24.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  25.                              , BtnFirst,       Prop_TDBNavigator_BtnFirst );
  26.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  27.                              , BtnPrevious,    Prop_TDBNavigator_BtnPrevious );
  28.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  29.                              , BtnNext,        Prop_TDBNavigator_BtnNext );
  30.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  31.                              , BtnLast,        Prop_TDBNavigator_BtnLast );
  32.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  33.                              , BtnInsert,      Prop_TDBNavigator_BtnInsert );
  34.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  35.                              , BtnDelete,      Prop_TDBNavigator_BtnDelete );
  36.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  37.                              , BtnEdit,        Prop_TDBNavigator_BtnEdit );
  38.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  39.                              , BtnPost,        Prop_TDBNavigator_BtnPost );
  40.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  41.                              , BtnCancel,      Prop_TDBNavigator_BtnCancel );
  42.     DECLARE_DB_PROP_RW1( ENUM, TBtnState
  43.                              , BtnRefresh,     Prop_TDBNavigator_BtnRefresh );
  44.     DECLARE_DB_PROP_RW0( Bool,  ConfirmDelete, Prop_TDBNavigator_ConfirmDelete );
  45.   private:
  46.     DECLARE_DB_PROP_RW1( ENUM, TNavigateBtn
  47.                              , ClickButton,    Prop_TDBNavigator_ClickButton );
  48.  
  49.   public:
  50.     // Methods
  51.     void BtnClick( TNavigateBtn );
  52.  
  53.  
  54.   private:
  55.     void FireOnClick( TNavigateBtn Btn )
  56.     {
  57.       OnClickSource( *this, Btn );
  58.     }
  59.     void FireOnDragDrop( TVbxControl& Source, SHORT x, SHORT y )
  60.     {
  61.       OnDragDropSource( *this, Source, x, y );
  62.     }
  63.     void FireOnDragOver( TVbxControl& Source, SHORT x, SHORT y, TDragState State )
  64.     {
  65.       OnDragOverSource( *this, Source, x, y, State );
  66.     }
  67.     void FireOnEndDrag( TVbxControl& Source, SHORT x, SHORT y )
  68.     {
  69.       OnEndDragSource( *this, Source, x, y );
  70.     }
  71.     void FireOnReSize()
  72.     {
  73.       OnReSizeSource( *this );
  74.     }
  75.     void FireOnDblClick()
  76.     {
  77.       OnDblClickSource( *this );
  78.     }
  79.     void FireOnEnter()
  80.     {
  81.       OnEnterSource( *this );
  82.     }
  83.     void FireOnExit()
  84.     {
  85.       OnExitSource( *this );
  86.     }
  87.  
  88.   public:
  89.     // Event Source
  90.     DECLARE_SOURCE( OnClick,    TDBNavigatorClick );
  91.     DECLARE_SOURCE( OnDblClick, TDBNavigatorNotify );
  92.     DECLARE_SOURCE( OnDragDrop, TDBNavigatorDrag );
  93.     DECLARE_SOURCE( OnDragOver, TDBNavigatorDragOver );
  94.     DECLARE_SOURCE( OnEndDrag,  TDBNavigatorDrag );
  95.     DECLARE_SOURCE( OnEnter,    TDBNavigatorNotify );
  96.     DECLARE_SOURCE( OnExit,     TDBNavigatorNotify );
  97.     DECLARE_SOURCE( OnReSize,   TDBNavigatorNotify );
  98.  
  99.     // Event Handlers
  100.     DECLARE_DB_EVENT( OnClick,    TNavClick );
  101.     DECLARE_DB_EVENT( OnDragDrop, TDragEvent );
  102.     DECLARE_DB_EVENT( OnDragOver, TDragOverEvent );
  103.     DECLARE_DB_EVENT( OnEndDrag,  TDragEvent );
  104.     DECLARE_DB_EVENT( OnDblClick, TNotifyEvent );
  105.     DECLARE_DB_EVENT( OnEnter,    TNotifyEvent );
  106.     DECLARE_DB_EVENT( OnExit,     TNotifyEvent );
  107.     DECLARE_DB_EVENT( OnReSize,   TNotifyEvent );
  108.  
  109.   protected:
  110.     char far* GetClassName();
  111.  
  112. #ifdef __OWL_VBXCTL_H
  113.   DECLARE_RESPONSE_TABLE( TDBNavigator );
  114. #endif __OWL_VBXCTL_H
  115. };
  116.  
  117. // Inlines
  118. // Methods
  119. inline void TDBNavigator::BtnClick( TNavigateBtn Btn )
  120. {
  121.   ClickButton = Btn;
  122. }
  123.  
  124. inline char far* TDBNavigator::GetClassName()
  125. {
  126.   return "DBNAVIGATOR";
  127. }
  128.  
  129. #endif  DBNAVIGATOR_H_
  130.