]> git.saurik.com Git - wxWidgets.git/blobdiff - src/osx/carbon/dataview.cpp
Check index in wxItemContainer methods working with client data.
[wxWidgets.git] / src / osx / carbon / dataview.cpp
index 48cb63956e9823a54e5df72e0fd3db75dc780ab3..680d368ea0962d073e3ccca064c020790ce902dd 100644 (file)
@@ -2746,6 +2746,16 @@ void wxDataViewColumn::SetWidth(int width)
 {
   wxDataViewCtrl* dataViewCtrlPtr(GetOwner());
 
+  switch ( width )
+  {
+    case wxCOL_WIDTH_AUTOSIZE:
+       // not implemented, fall through
+    case wxCOL_WIDTH_DEFAULT:
+      width = wxDVC_DEFAULT_WIDTH;
+      break;
+    default:
+      break;
+  }
 
   if ((width >= m_minWidth) && (width <= m_maxWidth))
   {