views::ImageButton: Added SetMinimumImageSize; removed SetPreferredSize.
ImageButton::SetMinimumImageSize allows the client to explicitly set a size larger than the image contained within the button. The image will be aligned inside the button according to its alignment setting. ImageButton::SetPreferredSize had a misleading name (since in fact it only sets the size when there is no image) and is no longer needed. Its original usage (r50040) is now gone. It wasn't having any effect in either of its two remaining callers, since they always set an image immediately afterwards. Therefore, deleted this method and removed both calls to it. Note that we are keeping the default behaviour that an ImageButton with no image has a size of 16x14. I wanted to remove this, but the list of potential clients that could be relying on it is huge. BUG=415909 Review URL: https://codereview.chromium.org/583843003 Cr-Commit-Position: refs/heads/master@{#295917}
Showing
Please register or sign in to comment