window.print() is not supported in iframes |
|||||
Issue descriptionApp Version (from "Chrome Settings > About Chrome"): M69 and older iOS Version: All Device: All Steps to reproduce: 1.) Load https://www.w3schools.com/jsref/tryit.asp?filename=tryjsref_print 2.) Tap Print This Page Observed behavior: Nothing happens Expected behavior: Print dialog should be presented
,
Sep 7
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/38715a153906cdfcf5b6c09765374c92cc821f9d commit 38715a153906cdfcf5b6c09765374c92cc821f9d Author: Eugene But <eugenebut@google.com> Date: Fri Sep 07 21:02:14 2018 Support window.print() in iframes. window.print() will work in iframes only if the user is interacting with the page. This will prevent abusive experience from malicious iframes. This CL does not have tests, because there is no infrastructure for testing PrintTabHelper, AddScriptCommandCallback and iframes. Bug: 881876 Cq-Include-Trybots: luci.chromium.try:ios-simulator-cronet;luci.chromium.try:ios-simulator-full-configs Change-Id: Ia741e74accf69b6cee63351e04851e3068e8c3e5 Reviewed-on: https://chromium-review.googlesource.com/1213270 Reviewed-by: Mike Dougherty <michaeldo@chromium.org> Commit-Queue: Eugene But <eugenebut@chromium.org> Cr-Commit-Position: refs/heads/master@{#589632} [modify] https://crrev.com/38715a153906cdfcf5b6c09765374c92cc821f9d/ios/chrome/browser/web/print_tab_helper.mm
,
Sep 7
,
Sep 8
Still need to inject scripts.
,
Sep 11
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/0227cbd7d0c2e47c1c8f5ad57df3fc2403c2a606 commit 0227cbd7d0c2e47c1c8f5ad57df3fc2403c2a606 Author: Eugene But <eugenebut@chromium.org> Date: Tue Sep 11 00:36:17 2018 Inject print.js into all frames. Bug: 881876 Cq-Include-Trybots: luci.chromium.try:ios-simulator-cronet;luci.chromium.try:ios-simulator-full-configs Change-Id: Id32427383dc90c986bb6ddf3cf07b0e1fc3f5282 Reviewed-on: https://chromium-review.googlesource.com/1214756 Reviewed-by: Mike Dougherty <michaeldo@chromium.org> Commit-Queue: Eugene But <eugenebut@chromium.org> Cr-Commit-Position: refs/heads/master@{#590139} [modify] https://crrev.com/0227cbd7d0c2e47c1c8f5ad57df3fc2403c2a606/ios/chrome/browser/web/BUILD.gn [modify] https://crrev.com/0227cbd7d0c2e47c1c8f5ad57df3fc2403c2a606/ios/chrome/browser/web/chrome_web_client_unittest.mm [modify] https://crrev.com/0227cbd7d0c2e47c1c8f5ad57df3fc2403c2a606/ios/chrome/browser/web/resources/chrome_bundle_all_frames.js [modify] https://crrev.com/0227cbd7d0c2e47c1c8f5ad57df3fc2403c2a606/ios/chrome/browser/web/resources/chrome_bundle_main_frame.js
,
Sep 11
,
Sep 18
Verified on 71.0.3555.0 Canary, iPhone X iOS 11.4.1, iPhone 7 iOS 12.0 Print dialog opens, looks good. |
|||||
►
Sign in to add a comment |
|||||
Comment 1 by eugene...@chromium.org
, Sep 7Status: Started (was: Available)