From d691c48ca6e86792381e393d6a1853da902a12fa Mon Sep 17 00:00:00 2001 From: John Scipione Date: Fri, 30 Aug 2013 23:17:03 -0400 Subject: [PATCH] Tracker: get StringWidth of menuField, not view --- src/kits/tracker/FindPanel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/kits/tracker/FindPanel.cpp b/src/kits/tracker/FindPanel.cpp index 51790537eb..94d4fcfa43 100644 --- a/src/kits/tracker/FindPanel.cpp +++ b/src/kits/tracker/FindPanel.cpp @@ -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) {