Fix text wrapping problem in the download_item_controller on Yosemite.
The code in [DownloadItemController showDangerousWarning:] calls [GTMUILocalizerAndLayoutTweaker sizeToFitFixedHeightTextField:minWidth:] to wrap the warning string within the DownloadItemController's dangerousDownloadLabel_ textField. Within the nib this textField is 22 points tall and holds two lines of text. Under Yosemite, however, the font metrics have changed and the two lines are now 24 points tall. This cl insets the dangerousDownloadLabel_'s frame height by -2 points when running on Yosemite. dangerousDownloadLabel_ is not as tall as its superview, so the new frame still fits comfortably within the superview's frame. BUG=454782 TEST=Follow instructions in bug 454782 and confirm that text is wrapping properly on Yosemite. Review URL: https://codereview.chromium.org/911303002 Cr-Commit-Position: refs/heads/master@{#318927}
Showing
Please register or sign in to comment