]> git.saurik.com Git - wxWidgets.git/blobdiff - demos/dbbrowse/dbgrid.h
Added wxDbTable::SetOrderByColNums() function
[wxWidgets.git] / demos / dbbrowse / dbgrid.h
index 85094de5f6e00ae2b7cb08a640293af0de63994a..9335dddcd63f75ee51a80c6545c90a099388dd8d 100644 (file)
@@ -1,58 +1,65 @@
-//---------------------------------------------------------------------------
+//----------------------------------------------------------------------------------------
 // Name:        DBGrid.h
-// Purpose:     DBGrid
+// Purpose:     shows seleted Table in a Grid
 // Author:      Mark Johnson
 // Modified by: 20000126.mj10777
 // Created:
-// RCS-ID:
 // Copyright:   (c) Mark Johnson
 // Licence:     wxWindows license
-//---------------------------------------------------------------------------
-class mjDoc;
-//---------------------------------------------------------------------------
+// RCS-ID:      $Id$
+//----------------------------------------------------------------------------------------
+#if !defined(wxUSE_NEW_GRID) || !(wxUSE_NEW_GRID)
+ #error "DBGrid requires the new wxGrid class"
+#endif
+//----------------------------------------------------------------------------------------
+class MainDoc;
+//----------------------------------------------------------------------------------------
 class DBGrid: public wxGrid
 {
  public:
   DBGrid(wxWindow *parent, const wxWindowID id,const wxPoint& pos,const wxSize& size, long style);
   virtual ~DBGrid();
- //-------------------------------------------
+ //---------------------------------------------------------------------------------------
   int        i_TabArt;   // Tab = 0 ; Page = 1;
   int        i_ViewNr;   // View Nummer in Tab / Page
   int        i_Which;    // Which View, Database is this/using
- //-------------------------------------------
-  wxFont*    f_Temp;
-  mjDoc*     pDoc;
+ //---------------------------------------------------------------------------------------
+  MainDoc*   pDoc;
   wxDbInf*   ct_BrowserDB;
   BrowserDB* db_Br;
   wxMenu   *popupMenu1; // OnDBClass
   wxMenu   *popupMenu2; // OnDBGrid & OnTableclass
   bool     b_EditModus;
- //-------------------------------------------
+ //---------------------------------------------------------------------------------------
   wxString logBuf,Temp0;
   wxPoint  MousePos;
- //-------------------------------------------
- void OnModusEdit(wxMenu& menu, wxCommandEvent& event);
- void OnModusBrowse(wxMenu& menu, wxCommandEvent& event);
+ //---------------------------------------------------------------------------------------
+ void OnModusEdit(wxCommandEvent& event);
+ void OnModusBrowse(wxCommandEvent& event);
  void OnMouseMove(wxMouseEvent& event);
  int  OnTableView(wxString Table);
- void OnLabelLeftClick( wxGridEvent& );
- void OnLabelRightClick( wxGridEvent& );
- void OnLabelLeftDClick( wxGridEvent& );
- void OnLabelRightDClick( wxGridEvent& );
+ //-----
+ void OnCellChange( wxGridEvent& );
  void OnCellLeftClick( wxGridEvent& );
- void OnCellRightClick( wxGridEvent& );
  void OnCellLeftDClick( wxGridEvent& );
+ void OnCellRightClick( wxGridEvent& );
  void OnCellRightDClick( wxGridEvent& );
- void OnRowSize( wxGridSizeEvent& );
  void OnColSize( wxGridSizeEvent& );
+ void OnEditorShown( wxGridEvent& );
+ void OnEditorHidden( wxGridEvent& );
+ void OnLabelLeftClick( wxGridEvent& );
+ void OnLabelLeftDClick( wxGridEvent& );
+ void OnLabelRightClick( wxGridEvent& );
+ void OnLabelRightDClick( wxGridEvent& );
  void OnRangeSelected( wxGridRangeSelectEvent& );
- void OnCellChange( wxGridEvent& );
- //-------------------------------------------
+ void OnRowSize( wxGridSizeEvent& );
+ void OnSelectCell( wxGridEvent& );
+ //---------------------------------------------------------------------------------------
  DECLARE_EVENT_TABLE()
 };
-//---------------------------------------------------------------------------
+//----------------------------------------------------------------------------------------
 #define GRID_01_BEGIN      1200
 #define GRID_BROWSE        1201
 #define GRID_EDIT          1202
 #define GRID_01_END        1203
-//------------------------------------------------------------------------------
+//----------------------------------------------------------------------------------------