New issue
Advanced search Search tips

Issue 810970 link

Starred by 2 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

Automatically pad a dialog's body content to align with the icon

Project Member Reported by bsep@chromium.org, Feb 10 2018

Issue description

If a dialog has an icon (i.e. returns an image from GetWindowIcon) the body content should be aligned with the icon automatically. Right now each dialog has to do this manually.

Dialogs currently don't have any default body padding, which makes this a bit harder.

The padding calculation could look like this (from grt@'s WIP patch):

gfx::Point origin = {};
views::View::ConvertPointToWidget(GetBubbleFrameView()->title(), &origin);
views::View::ConvertPointFromWidget(this, &origin);
int additional_body_padding = origin.x();
 
Project Member

Comment 1 by bugdroid1@chromium.org, Jun 4 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6ab4cb38d8cda822caf12ae2a4df86626321c4d2

commit 6ab4cb38d8cda822caf12ae2a4df86626321c4d2
Author: Trent Apted <tapted@chromium.org>
Date: Mon Jun 04 00:59:17 2018

Fix Layout() of RelaunchRecommendedBubbleView.

It was reporting a preferred size inconsistent with its Layout(), causing
potential clipping.

To fix, anticipate the required alignment using constants.

Bug: 847904, 810970
Change-Id: I78e7aa3dbfe04d3cd6695047aca74627b3186336
Reviewed-on: https://chromium-review.googlesource.com/1082057
Reviewed-by: Bret Sepulveda <bsep@chromium.org>
Commit-Queue: Trent Apted <tapted@chromium.org>
Cr-Commit-Position: refs/heads/master@{#563982}
[modify] https://crrev.com/6ab4cb38d8cda822caf12ae2a4df86626321c4d2/chrome/browser/ui/views/relaunch_notification/relaunch_recommended_bubble_view.cc

Project Member

Comment 2 by bugdroid1@chromium.org, Jun 7 2018

Labels: merge-merged-3440
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/64569f8718404fe10c76d4928970af6e852faa4a

commit 64569f8718404fe10c76d4928970af6e852faa4a
Author: Trent Apted <tapted@chromium.org>
Date: Thu Jun 07 03:59:36 2018

[merge-m68] Fix Layout() of RelaunchRecommendedBubbleView.

It was reporting a preferred size inconsistent with its Layout(), causing
potential clipping.

To fix, anticipate the required alignment using constants.

TBR=tapted@chromium.org

(cherry picked from commit 6ab4cb38d8cda822caf12ae2a4df86626321c4d2)

Bug: 847904, 810970
Change-Id: I78e7aa3dbfe04d3cd6695047aca74627b3186336
Reviewed-on: https://chromium-review.googlesource.com/1082057
Reviewed-by: Bret Sepulveda <bsep@chromium.org>
Commit-Queue: Trent Apted <tapted@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#563982}
Reviewed-on: https://chromium-review.googlesource.com/1090412
Reviewed-by: Trent Apted <tapted@chromium.org>
Cr-Commit-Position: refs/branch-heads/3440@{#230}
Cr-Branched-From: 010ddcfda246975d194964ccf20038ebbdec6084-refs/heads/master@{#561733}
[modify] https://crrev.com/64569f8718404fe10c76d4928970af6e852faa4a/chrome/browser/ui/views/relaunch_notification/relaunch_recommended_bubble_view.cc

Labels: Hotlist-DesktopUIValid Hotlist-DesktopUIChecked
Status: WontFix (was: Available)
*** Mass UI Triage *** 

Closing this issue as fix is landed. 
The patch in this bug isn't a fix. We could still do this, but it's probably not worth keeping the bug open if there's no plan to do it imminently.
Status: Available (was: WontFix)
I'd like to keep this sort of thing open as an RFE to the toolkit.

Sign in to add a comment