]> git.saurik.com Git - wxWidgets.git/commitdiff
fix unused variable warning in release build
authorVadim Zeitlin <vadim@wxwidgets.org>
Wed, 17 Dec 2008 11:30:31 +0000 (11:30 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Wed, 17 Dec 2008 11:30:31 +0000 (11:30 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57397 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/rearrangectrl.cpp

index de8b901fb25bf63031488fbe22c4fc55d5d284f5..a6af763370d0f2bb67b245099c7ded4809def99f 100644 (file)
@@ -139,11 +139,10 @@ void wxRearrangeList::OnCheck(wxCommandEvent& event)
     // update the internal state to match the new item state
     const int n = event.GetInt();
 
-    const bool checked = IsChecked(n);
-    wxASSERT_MSG( (m_order[n] >= 0) == !checked,
-                  "discrepancy between internal state and GUI" );
-
     m_order[n] = ~m_order[n];
+
+    wxASSERT_MSG( (m_order[n] >= 0) == IsChecked(n),
+                  "discrepancy between internal state and GUI" );
 }
 
 // ============================================================================