New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 601341 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: May 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 1
Type: Bug-Regression



Sign in to add a comment

Regression : Unwanted gray space is seen at the bottom of PrintPreview page after pressing Tab key.

Reported by yfulgaon...@etouch.net, Apr 7 2016

Issue description

Chrome version : 51.0.2702.0 (Official Build) 208b9d3c98bb3f1612ecc7c5e4abe49f8ea75210-refs/heads/master@{#385602} 32/64 bit
OS : Windows (Win 7 aero enabled)

Steps : 
1. Launch chrome, go to chrome://settings and hit Ctrl+A
2. Now press Ctrl+P and click zoom in button twice in PrintPreview.
3. Now hit Tab key 4-5 time and observe.

Actual : Unwanted gray space is seen at the bottom of PrintPreview page after pressing Tab key.
Expected : Unwanted gray space should not be seen in PrintPreview.

This is a regression issue broken in 'M-51', below is the manual regression and will soon update other info.
Good Build :  51.0.2699.0
Bad Build :  51.0.2700.0

 
Actual_print_prev.mp4
944 KB Download
Labels: hasbisect OS-Linux OS-Mac
Owner: tkent@chromium.org
Status: Assigned (was: Unconfirmed)
Narrow Bisect : 
https://chromium.googlesource.com/chromium/src/+log/34d768eb8c2c2bdd8e9cd259a0661b31d5f4c303..6a8a55c8d9a949f974a30b55f7c500281a9d12bb?pretty=fuller&n=10000

Suspecting : r384869  from narrow bisect

Comment 2 by tkent@chromium.org, Apr 7 2016

Cc: tkent@chromium.org alekseys@chromium.org
Owner: ----
Status: Untriaged (was: Assigned)
It seems my change exposed an existing problem of print preview.  It has hidden, but focusable, INPUT elements with class=margin-control-textbox.
I'm not sure what's the intention of the INPUT element.

Cc: -nyerramilli@chromium.org thestig@chromium.org shrike@chromium.org
tkent@ - I don't think it's kosher to just slough off a p1 regression that resulted from a change you landed.

thestig@ - any ideas who should look at this?

Comment 4 by tkent@chromium.org, Apr 12 2016

Cc: kmadhusu@chromium.org gene@chromium.org vitalyb...@chromium.org dpa...@chromium.org
Add more print_preview people.
I'm happy to fix this if I understand the intention of these class=margin-control-textbox elements.

Comment 5 by tkent@chromium.org, Apr 27 2016

ping print_preview owners
Why class=margin-control-textbox is focusable?

Cc: -kmadhusu@chromium.org -vitalyb...@chromium.org -gene@chromium.org -dpa...@chromium.org -alekseys@chromium.org
Owner: dpa...@chromium.org

Comment 7 by dpa...@chromium.org, Apr 27 2016

The textbox is focusable because the user can manually edit the value after selecting "Custom" margins (see screenshot).

I can reproduce the problem even when the textbox is not hidden (by turning on "Custom" margins and repeating the rerpo step number 3, so making the textbox not focusable when hidden does not seem sufficient anyway.
focusable_textbox.png
80.5 KB View Download

Comment 8 by dpa...@chromium.org, Apr 27 2016

Also the repro steps can be simplified.

1. Launch chrome, go to any page (no need to select any text).
2. Now press Ctrl+P and click zoom until only part of the first page is visible.
3. Now hit Tab key 4-5 time and observe.

Comment 9 by tkent@chromium.org, Apr 27 2016

#7, thank you for the information.  I understand the situation.

Blink scrolls <div id=preview-area> to show a focused margin-control-textbox, but overflowed area including the margin-control-textbox is not drawn because the div has overflow:hidden.  The div is not intended to be scrolled.

Margin-control-textboxes should be descendants of the scrollable area.  But the scrollable area is an <iframe> hosting the plugin. We can't move margin-control-textboxes into it.
I guess changing the scrollable area from the <iframe> to another element needs a huge change.

So I think a short-term fix would be:
 - Add focus handler to margin-control-textboxes, and it resets scroll position of <div id=preview-area>, AND
 - Make maargin-control-textboxes unfocusable if not in custom margin mode.

Focused margin-control-textbox would be invisible as ever.


Comment 10 by tkent@chromium.org, Apr 27 2016

I made a quick workaround.
https://codereview.chromium.org/1917413002

Project Member

Comment 11 by bugdroid1@chromium.org, May 2 2016

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

commit dedbae45b850e09e8de724bc678cbec27a7ed6c8
Author: tkent <tkent@chromium.org>
Date: Mon May 02 08:18:20 2016

print_preview: Workaround of focus-scroll issue.

* Make margin-control-textbox elements unfocusable if not in custom margin mode.

* Reset the scroll position of preview-area when margin-control-textbox is
  focused.

BUG= 601341 
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:closure_compilation

Review-Url: https://codereview.chromium.org/1917413002
Cr-Commit-Position: refs/heads/master@{#390902}

[modify] https://crrev.com/dedbae45b850e09e8de724bc678cbec27a7ed6c8/chrome/browser/resources/print_preview/previewarea/margin_control.js

Cc: dpa...@chromium.org
Labels: Merge-Request-51
Owner: tkent@chromium.org
Status: Fixed (was: Untriaged)

Comment 13 by tin...@google.com, May 3 2016

Labels: -Merge-Request-51 Merge-Approved-51 Hotlist-Merge-Approved
Your change meets the bar and is auto-approved for M51 (branch: 2704)

Comment 14 Deleted

Please merge your change to M51 branch 2704 by 5:00 PM PST Friday (05/06) so we can take it for next week beta release.Thank you.
@tkent: Are you planning to merge this?
I was ooo.  Will merge the fix soon.

Project Member

Comment 18 by bugdroid1@chromium.org, May 5 2016

Labels: -merge-approved-51 merge-merged-2704
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9e9ef8f9049d13aea9310d16ecc145b24becbc3b

commit 9e9ef8f9049d13aea9310d16ecc145b24becbc3b
Author: Kent Tamura <tkent@chromium.org>
Date: Thu May 05 23:21:59 2016

Merge "print_preview: Workaround of focus-scroll issue." to M51

* Make margin-control-textbox elements unfocusable if not in custom margin mode.

* Reset the scroll position of preview-area when margin-control-textbox is
  focused.

BUG= 601341 
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:closure_compilation

Review-Url: https://codereview.chromium.org/1917413002
Cr-Commit-Position: refs/heads/master@{#390902}
(cherry picked from commit dedbae45b850e09e8de724bc678cbec27a7ed6c8)

Review URL: https://codereview.chromium.org/1954763003 .

Cr-Commit-Position: refs/branch-heads/2704@{#403}
Cr-Branched-From: 6e53600def8f60d8c632fadc70d7c1939ccea347-refs/heads/master@{#386251}

[modify] https://crrev.com/9e9ef8f9049d13aea9310d16ecc145b24becbc3b/chrome/browser/resources/print_preview/previewarea/margin_control.js

Sign in to add a comment