Tracker: get StringWidth of menuField, not view
This commit is contained in:
@@ -955,7 +955,7 @@ FindPanel::ResizeMenuField(BMenuField* menuField)
|
|||||||
for (int32 index = menu->CountItems(); index-- > 0; ) {
|
for (int32 index = menu->CountItems(); index-- > 0; ) {
|
||||||
BMenuItem* item = menu->ItemAt(index);
|
BMenuItem* item = menu->ItemAt(index);
|
||||||
if (item->Label() != NULL)
|
if (item->Label() != NULL)
|
||||||
width = std::max(width, StringWidth(item->Label()));
|
width = std::max(width, menuField->StringWidth(item->Label()));
|
||||||
|
|
||||||
BMenu* submenu = item->Submenu();
|
BMenu* submenu = item->Submenu();
|
||||||
if (submenu != NULL) {
|
if (submenu != NULL) {
|
||||||
|
|||||||
Reference in New Issue
Block a user