Delay querying for printers list until the policy file is parsed
A list of enterpise printers is not ready immediately after creation of CupsPrintersManager. It caused a problem for testing procedure since from the level of autotest_private_api we do not know if the final list is ready or there are still some ongoing calculations. A new method called OnEnterprisePrintersInitialized() was added to the observer of CupsPrintersManager to solve this issue. Also whole code related to enterprise printers were refactored, large part of functionality was moved from SyncedPrintersManager to new class EnterprisePrintersProvider. Classes ExternalPrintersPrefBridge and DeviceExternalPrintersSettingsBridge have been merged into one class called CalculatorsPoliciesBinder. This is reland of CL:1220547, it fixes the problem detected by the test AutotestPrivateApiTest.AutotestPrivate (method execution after destruction of CupsPrintersManager object). BUG=chromium:816996 TEST=Tested on cave with the use of CL:1451591 TBR=achuith@chromium.org Change-Id: I70958421aadd9fab9a2401555bef0dbb28ad5a6a Reviewed-on: https://chromium-review.googlesource.com/c/1491909 Commit-Queue: Piotr Pawliczek <pawliczek@chromium.org> Reviewed-by:Sean Kau <skau@chromium.org> Reviewed-by:
Maksim Ivanov <emaxx@chromium.org> Auto-Submit: Piotr Pawliczek <pawliczek@chromium.org> Cr-Commit-Position: refs/heads/master@{#636618}
Showing
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Please register or sign in to comment