]> git.saurik.com Git - wxWidgets.git/blobdiff - src/ribbon/art_msw.cpp
Let wxMSW report wxDataViewCustomRenderer::LeftClick() report the click position...
[wxWidgets.git] / src / ribbon / art_msw.cpp
index 32d0e2acdb050cf13dd4004b00a42c69810036ca..3d42946d526c990d83e512be861da82eaf9e4888 100644 (file)
     #pragma hdrstop
 #endif
 
-#include "wx/dcmemory.h"
-#include "wx/ribbon/art.h"
-
 #if wxUSE_RIBBON
 
+#include "wx/ribbon/art.h"
 #include "wx/ribbon/art_internal.h"
 #include "wx/ribbon/bar.h"
 #include "wx/ribbon/buttonbar.h"
@@ -27,6 +25,7 @@
 #include "wx/ribbon/toolbar.h"
 
 #ifndef WX_PRECOMP
+#include "wx/dcmemory.h"
 #endif
 
 #ifdef __WXMSW__
@@ -2446,6 +2445,8 @@ wxSize wxRibbonMSWArtProvider::GetPanelClientSize(
         else
             *client_offset = wxPoint(3, 2);
     }
+    if (size.x < 0) size.x = 0;
+    if (size.y < 0) size.y = 0;
 
     return size;
 }