X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c9f7896861f734ce044ee8601ba2d8a6959c9d9e..198be845897a79ba350ae7f93db536ddb2eccfb2:/src/msw/ownerdrw.cpp diff --git a/src/msw/ownerdrw.cpp b/src/msw/ownerdrw.cpp index f527ed834b..12f6d210bc 100644 --- a/src/msw/ownerdrw.cpp +++ b/src/msw/ownerdrw.cpp @@ -198,7 +198,10 @@ bool wxOwnerDrawn::OnMeasureItem(size_t *pwidth, size_t *pheight) dc.SetFont(GetFontToUse()); - dc.GetTextExtent(str, (long *)pwidth, (long *)pheight); + wxCoord w, h; + dc.GetTextExtent(str, &w, &h); + *pwidth = w; + *pheight = h; // add space at the end of the menu for the submenu expansion arrow // this will also allow offsetting the accel string from the right edge