Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(92)

Unified Diff: ui/views/controls/tree/tree_view.cc

Issue 24883002: Uses and returns the fractional width in text eliding (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/views/controls/tree/tree_view.cc
diff --git a/ui/views/controls/tree/tree_view.cc b/ui/views/controls/tree/tree_view.cc
index 78d4693e4a7fafecd0230d8bc0b5fe479580b1ee..b5da43fc00e5edd0fddcb1f20e1f3b03dde90146 100644
--- a/ui/views/controls/tree/tree_view.cc
+++ b/ui/views/controls/tree/tree_view.cc
@@ -674,7 +674,7 @@ void TreeView::ConfigureInternalNode(TreeModelNode* model_node,
}
void TreeView::UpdateNodeTextWidth(InternalNode* node) {
- int width = 0, height = 0;
+ float width = 0, height = 0;
gfx::Canvas::SizeStringInt(node->model_node()->GetTitle(), font_,
&width, &height, 0, gfx::Canvas::NO_ELLIPSIS);
node->set_text_width(width);

Powered by Google App Engine
This is Rietveld 408576698