Index: ui/views/controls/textfield/textfield.cc |
diff --git a/ui/views/controls/textfield/textfield.cc b/ui/views/controls/textfield/textfield.cc |
index d386e633938a7ec3b23db4ca8d1e84f2d21a1037..68aa01ec3bd832958bcc74db80c22734a5f3398c 100644 |
--- a/ui/views/controls/textfield/textfield.cc |
+++ b/ui/views/controls/textfield/textfield.cc |
@@ -481,7 +481,7 @@ int Textfield::GetBaseline() const { |
return GetInsets().top() + GetRenderText()->GetBaseline(); |
} |
-gfx::Size Textfield::GetPreferredSize() { |
+gfx::Size Textfield::GetPreferredSize() const { |
const gfx::Insets& insets = GetInsets(); |
return gfx::Size(GetFontList().GetExpectedTextWidth(default_width_in_chars_) + |
insets.width(), GetFontList().GetHeight() + insets.height()); |