X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bf9adb3a20644dd21be115606120a3767ef3716f..4e4a5fed9f544d3bec51b75b6e8638d4481d8534:/samples/newgrid/griddemo.cpp diff --git a/samples/newgrid/griddemo.cpp b/samples/newgrid/griddemo.cpp index 28c51cd7f1..c93a563918 100644 --- a/samples/newgrid/griddemo.cpp +++ b/samples/newgrid/griddemo.cpp @@ -30,10 +30,11 @@ #ifndef WX_PRECOMP #include "wx/wx.h" - #include "wx/colordlg.h" - #include "wx/fontdlg.h" #endif +#include "wx/colordlg.h" +#include "wx/fontdlg.h" + #include "wx/grid.h" #include "wx/generic/gridctrl.h" @@ -599,8 +600,8 @@ void GridFrame::DeleteSelectedRows( wxCommandEvent& WXUNUSED(ev) ) for ( int n = 0; n < grid->GetNumberRows(); ) if ( grid->IsInSelection( n , 0 ) ) grid->DeleteRows( n, 1 ); - else - n++; + else + n++; grid->EndBatch(); } } @@ -614,8 +615,8 @@ void GridFrame::DeleteSelectedCols( wxCommandEvent& WXUNUSED(ev) ) for ( int n = 0; n < grid->GetNumberCols(); ) if ( grid->IsInSelection( 0 , n ) ) grid->DeleteCols( n, 1 ); - else - n++; + else + n++; grid->EndBatch(); } } @@ -823,14 +824,13 @@ void GridFrame::OnEditorShown( wxGridEvent& ev ) if ( (ev.GetCol() == 4) && (ev.GetRow() == 0) && - (wxMessageBox(_T("Are you sure you wish to edit this cell"), - _T("Checking"),wxYES_NO) == wxNO ) ) { + (wxMessageBox(_T("Are you sure you wish to edit this cell"), + _T("Checking"),wxYES_NO) == wxNO ) ) { - ev.Veto(); - return; + ev.Veto(); + return; } - - + wxLogMessage( wxT("Cell editor shown.") ); ev.Skip(); @@ -841,11 +841,11 @@ void GridFrame::OnEditorHidden( wxGridEvent& ev ) if ( (ev.GetCol() == 4) && (ev.GetRow() == 0) && - (wxMessageBox(_T("Are you sure you wish to finish editing this cell"), - _T("Checking"),wxYES_NO) == wxNO ) ) { + (wxMessageBox(_T("Are you sure you wish to finish editing this cell"), + _T("Checking"),wxYES_NO) == wxNO ) ) { - ev.Veto(); - return; + ev.Veto(); + return; } wxLogMessage( wxT("Cell editor hidden.") );