Tracker: get StringWidth of menuField, not view

This commit is contained in:
John Scipione 2013-08-30 23:17:03 -04:00
parent 86af5f159b
commit d691c48ca6

View File

@ -955,7 +955,7 @@ FindPanel::ResizeMenuField(BMenuField* menuField)
for (int32 index = menu->CountItems(); index-- > 0; ) {
BMenuItem* item = menu->ItemAt(index);
if (item->Label() != NULL)
width = std::max(width, StringWidth(item->Label()));
width = std::max(width, menuField->StringWidth(item->Label()));
BMenu* submenu = item->Submenu();
if (submenu != NULL) {