Use correct BrowserContext in guest mode for CupsPrintersManagerFactory
First this change gives CupsPrintersManagerFactory access to the both the OffTheRecord(OTR) and non-OTR guest profile when logged into Guest mode. Before, using GetBrowserContextRedirectedInIncognito, only the non-OTR recording guest profile was available to BuildServiceInstanceFor. Second, this change filters to only create CupsPrintersManager with the OTR profile when in Guest mode. The OTR profile is needed by the UsbPrinterNotificationController to open the System Web App(SWA) Settings page to configure USB printers. There is a check (https://osscs.corp.google.com/chromium/chromium/src/+/master:chrome/browser/ui/browser.cc;l=471) that only OTR guest profiles are allowed to open SWAs. For the other profile users in CupsPrintersManager, there's no impact for using the OTR guest profile vs. the non-OTR guest profile. Fixed: 1116062 Change-Id: Icbc000f36f178cbf30f1a85dbbe94b16cfe1f3b2 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2368234 Commit-Queue: Gavin Williams <gavinwill@chromium.org> Reviewed-by:Bailey Berro <baileyberro@chromium.org> Reviewed-by:
Ramin Halavati <rhalavati@chromium.org> Reviewed-by:
Zentaro Kavanagh <zentaro@chromium.org> Cr-Commit-Position: refs/heads/master@{#800636}
Showing
Please register or sign in to comment