]> git.saurik.com Git - wxWidgets.git/blobdiff - src/generic/gridsel.cpp
Fixed GetIcon to keep up with return type change on all other platforms.
[wxWidgets.git] / src / generic / gridsel.cpp
index 285247170d512d28d714d88d360af4a2d613a050..f1d62b07f64764a477ec5f4b0e6734188bb230a9 100644 (file)
 // headers
 // ----------------------------------------------------------------------------
 
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
-    #pragma implementation "gridsel.h"
-#endif
-
 // For compilers that support precompilation, includes "wx/wx.h".
 #include "wx/wxprec.h"
 
@@ -91,7 +87,7 @@ bool wxGridSelection::IsInSelection ( int row, int col )
     // (unless we are in column selection mode).
     if ( m_selectionMode != wxGrid::wxGridSelectColumns )
     {
-        size_t count = m_rowSelection.GetCount();
+        count = m_rowSelection.GetCount();
         for ( size_t n = 0; n < count; n++ )
         {
             if ( row == m_rowSelection[n] )
@@ -104,7 +100,7 @@ bool wxGridSelection::IsInSelection ( int row, int col )
     // (unless we are in row selection mode).
     if ( m_selectionMode != wxGrid::wxGridSelectRows )
     {
-        size_t count = m_colSelection.GetCount();
+        count = m_colSelection.GetCount();
         for ( size_t n = 0; n < count; n++ )
         {
             if ( col == m_colSelection[n] )
@@ -443,14 +439,17 @@ void wxGridSelection::SelectBlock( int topRow, int leftCol,
                                coords2.GetRow(), coords2.GetCol(),
                                topRow, leftCol, bottomRow, rightCol ) )
         {
-          case 1:
-            return;
-          case -1:
-            m_blockSelectionTopLeft.RemoveAt(n);
-            m_blockSelectionBottomRight.RemoveAt(n);
-            n--; count--;
-          default:
-            ;
+            case 1:
+                return;
+
+            case -1:
+                m_blockSelectionTopLeft.RemoveAt(n);
+                m_blockSelectionBottomRight.RemoveAt(n);
+                n--; count--;
+                break;
+
+            default:
+                break;
         }
     }
 
@@ -465,13 +464,16 @@ void wxGridSelection::SelectBlock( int topRow, int leftCol,
                                    m_rowSelection[n], m_grid->GetNumberCols()-1,
                                    topRow, leftCol, bottomRow, rightCol ) )
             {
-              case 1:
-                return;
-              case -1:
-                m_rowSelection.RemoveAt(n);
-                n--; count--;
-              default:
-                ;
+                case 1:
+                    return;
+
+                case -1:
+                    m_rowSelection.RemoveAt(n);
+                    n--; count--;
+                    break;
+
+                default:
+                    break;
             }
         }
     }
@@ -484,13 +486,16 @@ void wxGridSelection::SelectBlock( int topRow, int leftCol,
                                    m_grid->GetNumberRows()-1, m_colSelection[n],
                                    topRow, leftCol, bottomRow, rightCol ) )
             {
-              case 1:
-                return;
-              case -1:
-                m_colSelection.RemoveAt(n);
-                n--; count--;
-              default:
-                ;
+                case 1:
+                    return;
+
+                case -1:
+                    m_colSelection.RemoveAt(n);
+                    n--; count--;
+                    break;
+
+                default:
+                    break;
             }
         }
     }
@@ -590,8 +595,8 @@ void wxGridSelection::ToggleCellSelection( int row, int col,
         count = m_cellSelection.GetCount();
         for ( n = 0; n < count; n++ )
         {
-            wxGridCellCoords& coords = m_cellSelection[n];
-            if ( row == coords.GetRow() && col == coords.GetCol() )
+            const wxGridCellCoords& sel = m_cellSelection[n];
+            if ( row == sel.GetRow() && col == sel.GetCol() )
             {
                 wxGridCellCoords coords = m_cellSelection[n];
                 m_cellSelection.RemoveAt(n);