git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38531 
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
                 m_waitForSlowClick = true;
             }
         }
                 m_waitForSlowClick = true;
             }
         }
-            if ( coords == m_currentCellCoords && m_waitForSlowClick && CanEnableCellControl())
+            if ( coords == m_currentCellCoords && m_waitForSlowClick && CanEnableCellControl() )
             {
                 ClearSelection();
                 EnableCellEditControl();
             {
                 ClearSelection();
                 EnableCellEditControl();
-    wxClientDC dc(m_gridWin);
-    PrepareDC(dc);
+    wxClientDC dc( m_gridWin );
+    PrepareDC( dc );
 
     if ( m_currentCellCoords != wxGridNoCellCoords )
     {
 
     if ( m_currentCellCoords != wxGridNoCellCoords )
     {
         if ( IsVisible( m_currentCellCoords, false ) )
         {
             wxRect r;
         if ( IsVisible( m_currentCellCoords, false ) )
         {
             wxRect r;
-            r = BlockToDeviceRect(m_currentCellCoords, m_currentCellCoords);
+            r = BlockToDeviceRect( m_currentCellCoords, m_currentCellCoords );
             if ( !m_gridLinesEnabled )
             {
                 r.x--;
             if ( !m_gridLinesEnabled )
             {
                 r.x--;
             // Otherwise refresh redraws the highlight!
             m_currentCellCoords = coords;
 
             // Otherwise refresh redraws the highlight!
             m_currentCellCoords = coords;
 
-            DrawGridCellArea(dc,cells);
+            DrawGridCellArea( dc, cells );
             DrawAllGridLines( dc, r );
         }
     }
 
     m_currentCellCoords = coords;
 
             DrawAllGridLines( dc, r );
         }
     }
 
     m_currentCellCoords = coords;
 
-    wxGridCellAttr* attr = GetCellAttr(coords);
-    DrawCellHighlight(dc, attr);
+    wxGridCellAttr *attr = GetCellAttr( coords );
+    DrawCellHighlight( dc, attr );
             CalcScrolledPosition( rect.x, rect.y, &rect.x, &rect.y );
 
             int nXMove = 0;
             CalcScrolledPosition( rect.x, rect.y, &rect.x, &rect.y );
 
             int nXMove = 0;
                 nXMove = rect.x;
 
             // done in PaintBackground()
                 nXMove = rect.x;
 
             // done in PaintBackground()
                     int c_rows, c_cols;
                     GetCellSize( row, i, &c_rows, &c_cols );
                     // looks weird going over a multicell
                     int c_rows, c_cols;
                     GetCellSize( row, i, &c_rows, &c_cols );
                     // looks weird going over a multicell
-                    if (m_table->IsEmptyCell(row,i) &&
+                    if (m_table->IsEmptyCell( row, i ) &&
                             (rect.width < maxWidth) && (c_rows == 1))
                             (rect.width < maxWidth) && (c_rows == 1))
-                        rect.width += GetColWidth(i);
+                        rect.width += GetColWidth( i );
                     else
                         break;
                 }
 
                 if (rect.GetRight() > client_right)
                     else
                         break;
                 }
 
                 if (rect.GetRight() > client_right)
-                    rect.SetRight(client_right - 1);
+                    rect.SetRight( client_right - 1 );
-            editor->SetCellAttr(attr);
+            editor->SetCellAttr( attr );
-            editor->GetControl()->Move(editor->GetControl()->GetPosition().x + nXMove, editor->GetControl()->GetPosition().y);
+            editor->GetControl()->Move( editor->GetControl()->GetPosition().x + nXMove, editor->GetControl()->GetPosition().y );
             editor->Show( true, attr );
 
             int colXPos = 0;
             for (int i = 0; i < m_currentCellCoords.GetCol(); i++)
             {
             editor->Show( true, attr );
 
             int colXPos = 0;
             for (int i = 0; i < m_currentCellCoords.GetCol(); i++)
             {
-                colXPos += GetColSize(i);
+                colXPos += GetColSize( i );
-            int xUnit=1, yUnit=1;
-            GetScrollPixelsPerUnit(&xUnit, &yUnit);
+
+            int xUnit = 1, yUnit = 1;
+            GetScrollPixelsPerUnit( &xUnit, &yUnit );
             if (m_currentCellCoords.GetCol() != 0)
             if (m_currentCellCoords.GetCol() != 0)
-                Scroll(colXPos/xUnit-1, GetScrollPos(wxVERTICAL));
+                Scroll( colXPos / xUnit - 1, GetScrollPos( wxVERTICAL ) );
-                Scroll(colXPos/xUnit, GetScrollPos(wxVERTICAL));
+                Scroll( colXPos / xUnit, GetScrollPos( wxVERTICAL ) );
 
             // recalc dimensions in case we need to
             // expand the scrolled window to account for editor
 
             // recalc dimensions in case we need to
             // expand the scrolled window to account for editor
         int row = m_currentCellCoords.GetRow();
         int col = m_currentCellCoords.GetCol();
 
         int row = m_currentCellCoords.GetRow();
         int col = m_currentCellCoords.GetCol();
 
-        wxGridCellAttr* attr = GetCellAttr(row, col);
+        wxGridCellAttr *attr = GetCellAttr(row, col);
         wxGridCellEditor *editor = attr->GetEditor(this, row, col);
         editor->Show( false );
         editor->DecRef();
         wxGridCellEditor *editor = attr->GetEditor(this, row, col);
         editor->Show( false );
         editor->DecRef();
     if ( m_currentCellCoords != wxGridNoCellCoords  &&
          m_currentCellCoords.GetRow() >= 0 )
     {
     if ( m_currentCellCoords != wxGridNoCellCoords  &&
          m_currentCellCoords.GetRow() >= 0 )
     {
         {
             if ( m_selectingKeyboard == wxGridNoCellCoords )
                 m_selectingKeyboard = m_currentCellCoords;
         {
             if ( m_selectingKeyboard == wxGridNoCellCoords )
                 m_selectingKeyboard = m_currentCellCoords;