Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(104)

Issue 2885363003: Add policy to use system default printer (Closed)

Created:
3 years, 7 months ago by rbpotter
Modified:
3 years, 6 months ago
CC:
arv+watch_chromium.org, chromium-reviews, Georges Khalil, pastarmovj, skau
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Add policy to use system default printer Add a policy/command line flag to use the system default printer as the default destination in Print Preview instead of the most recently used destination. BUG=375238 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation Review-Url: https://codereview.chromium.org/2885363003 Cr-Commit-Position: refs/heads/master@{#480908} Committed: https://chromium.googlesource.com/chromium/src/+/421c21956a3d5da8406d3aacec9e520b3653f904

Patch Set 1 #

Patch Set 2 : Add to histograms and JSON #

Patch Set 3 : Fix policy and rebase #

Patch Set 4 : Rebase again #

Patch Set 5 : Fix test #

Total comments: 12

Patch Set 6 : Address comments, add test #

Total comments: 2

Patch Set 7 : Fix dynamic refresh #

Total comments: 8

Patch Set 8 : Address comments #

Total comments: 6

Patch Set 9 : Remove IOS checks #

Unified diffs Side-by-side diffs Delta from patch set Stats (+129 lines, -11 lines) Patch
M chrome/browser/policy/configuration_policy_handler_list_factory.cc View 1 2 3 4 5 8 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/prefs/chrome_command_line_pref_store.cc View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/browser/resources/print_preview/data/destination_store.js View 1 2 3 4 5 6 7 2 chunks +12 lines, -3 lines 0 comments Download
M chrome/browser/ui/browser_ui_prefs.cc View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/browser/ui/webui/print_preview/print_preview_ui.cc View 1 2 3 4 5 6 chunks +10 lines, -7 lines 0 comments Download
M chrome/common/chrome_switches.h View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/common/chrome_switches.cc View 1 2 3 4 5 6 7 8 1 chunk +6 lines, -0 lines 0 comments Download
M chrome/common/pref_names.h View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/common/pref_names.cc View 1 2 3 4 5 6 7 8 1 chunk +7 lines, -0 lines 0 comments Download
M chrome/test/data/policy/policy_test_cases.json View 1 2 3 4 5 6 7 1 chunk +8 lines, -0 lines 0 comments Download
M chrome/test/data/webui/print_preview/print_preview_tests.js View 1 2 3 4 5 6 7 1 chunk +36 lines, -0 lines 0 comments Download
M chrome/test/data/webui/print_preview/print_preview_ui_browsertest.js View 1 2 3 4 5 6 7 1 chunk +7 lines, -0 lines 0 comments Download
M components/policy/resources/policy_templates.json View 1 2 3 4 5 6 7 2 chunks +23 lines, -1 line 0 comments Download
M tools/metrics/histograms/enums.xml View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 66 (44 generated)
rbpotter
3 years, 6 months ago (2017-06-14 18:17:35 UTC) #24
Lei Zhang
FWIW, I believe OS X and Windows 10 (not sure about 8) have a system ...
3 years, 6 months ago (2017-06-15 18:14:10 UTC) #25
Lei Zhang
+potentially interested folks FYI too.
3 years, 6 months ago (2017-06-15 18:17:18 UTC) #26
Lei Zhang
https://codereview.chromium.org/2885363003/diff/80001/chrome/common/chrome_switches.cc File chrome/common/chrome_switches.cc (right): https://codereview.chromium.org/2885363003/diff/80001/chrome/common/chrome_switches.cc#newcode842 chrome/common/chrome_switches.cc:842: // Overrides the use of the most recent destination ...
3 years, 6 months ago (2017-06-15 18:26:16 UTC) #27
Lei Zhang
Can we force-set "useSystemDefaultPrinter" to true in JS, and test the destination_store.js changes? https://codereview.chromium.org/2885363003/diff/80001/chrome/browser/ui/webui/print_preview/print_preview_ui.cc File ...
3 years, 6 months ago (2017-06-15 18:29:35 UTC) #28
skau
https://codereview.chromium.org/2885363003/diff/80001/chrome/browser/prefs/chrome_command_line_pref_store.cc File chrome/browser/prefs/chrome_command_line_pref_store.cc (right): https://codereview.chromium.org/2885363003/diff/80001/chrome/browser/prefs/chrome_command_line_pref_store.cc#newcode83 chrome/browser/prefs/chrome_command_line_pref_store.cc:83: {switches::kUseSystemDefaultPrinter, Can we exclude this from ChromeOS? It'll have ...
3 years, 6 months ago (2017-06-15 19:41:31 UTC) #30
rbpotter
https://codereview.chromium.org/2885363003/diff/80001/chrome/browser/prefs/chrome_command_line_pref_store.cc File chrome/browser/prefs/chrome_command_line_pref_store.cc (right): https://codereview.chromium.org/2885363003/diff/80001/chrome/browser/prefs/chrome_command_line_pref_store.cc#newcode83 chrome/browser/prefs/chrome_command_line_pref_store.cc:83: {switches::kUseSystemDefaultPrinter, On 2017/06/15 19:41:31, skau wrote: > Can we ...
3 years, 6 months ago (2017-06-16 02:21:46 UTC) #36
skau
lgtm Thanks!
3 years, 6 months ago (2017-06-16 03:47:49 UTC) #37
pastarmovj
Policy LGTM. https://codereview.chromium.org/2885363003/diff/100001/components/policy/resources/policy_templates.json File components/policy/resources/policy_templates.json (right): https://codereview.chromium.org/2885363003/diff/100001/components/policy/resources/policy_templates.json#newcode9638 components/policy/resources/policy_templates.json:9638: 'dynamic_refresh': False, Just to make sure - ...
3 years, 6 months ago (2017-06-16 08:23:41 UTC) #38
rbpotter
+dpapad for print preview JS changes and test. https://codereview.chromium.org/2885363003/diff/100001/components/policy/resources/policy_templates.json File components/policy/resources/policy_templates.json (right): https://codereview.chromium.org/2885363003/diff/100001/components/policy/resources/policy_templates.json#newcode9638 components/policy/resources/policy_templates.json:9638: 'dynamic_refresh': ...
3 years, 6 months ago (2017-06-16 17:51:25 UTC) #40
Lei Zhang
https://codereview.chromium.org/2885363003/diff/120001/chrome/browser/policy/configuration_policy_handler_list_factory.cc File chrome/browser/policy/configuration_policy_handler_list_factory.cc (right): https://codereview.chromium.org/2885363003/diff/120001/chrome/browser/policy/configuration_policy_handler_list_factory.cc#newcode619 chrome/browser/policy/configuration_policy_handler_list_factory.cc:619: { key::kPrintPreviewUseSystemDefaultPrinter, So if we are going to put ...
3 years, 6 months ago (2017-06-16 21:47:44 UTC) #41
dpapad
https://codereview.chromium.org/2885363003/diff/120001/chrome/browser/resources/print_preview/data/destination_store.js File chrome/browser/resources/print_preview/data/destination_store.js (right): https://codereview.chromium.org/2885363003/diff/120001/chrome/browser/resources/print_preview/data/destination_store.js#newcode175 chrome/browser/resources/print_preview/data/destination_store.js:175: * @type {boolean} Nit: @private {boolean} https://codereview.chromium.org/2885363003/diff/120001/chrome/test/data/webui/print_preview/print_preview_ui_browsertest.js File chrome/test/data/webui/print_preview/print_preview_ui_browsertest.js ...
3 years, 6 months ago (2017-06-19 17:43:37 UTC) #42
rbpotter
https://codereview.chromium.org/2885363003/diff/120001/chrome/browser/policy/configuration_policy_handler_list_factory.cc File chrome/browser/policy/configuration_policy_handler_list_factory.cc (right): https://codereview.chromium.org/2885363003/diff/120001/chrome/browser/policy/configuration_policy_handler_list_factory.cc#newcode619 chrome/browser/policy/configuration_policy_handler_list_factory.cc:619: { key::kPrintPreviewUseSystemDefaultPrinter, On 2017/06/16 21:47:43, Lei Zhang wrote: > ...
3 years, 6 months ago (2017-06-19 23:10:50 UTC) #46
Lei Zhang
+eugenebut to help answer the OS_IOS in chrome/ question. https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc File chrome/browser/policy/configuration_policy_handler_list_factory.cc (right): https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc#newcode621 chrome/browser/policy/configuration_policy_handler_list_factory.cc:621: ...
3 years, 6 months ago (2017-06-19 23:41:40 UTC) #47
Eugene But (OOO till 7-30)
https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc File chrome/browser/policy/configuration_policy_handler_list_factory.cc (right): https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc#newcode621 chrome/browser/policy/configuration_policy_handler_list_factory.cc:621: #if !defined(OS_CHROMEOS) && !defined(OS_ANDROID) && !defined(OS_IOS) On 2017/06/19 23:41:40, ...
3 years, 6 months ago (2017-06-20 00:53:58 UTC) #51
Lei Zhang
https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc File chrome/browser/policy/configuration_policy_handler_list_factory.cc (right): https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc#newcode621 chrome/browser/policy/configuration_policy_handler_list_factory.cc:621: #if !defined(OS_CHROMEOS) && !defined(OS_ANDROID) && !defined(OS_IOS) On 2017/06/20 00:53:57, ...
3 years, 6 months ago (2017-06-20 00:56:25 UTC) #52
Eugene But (OOO till 7-30)
> Thanks! Should we in a separate CL, clear out the OS_IOS usage in chrome/, ...
3 years, 6 months ago (2017-06-20 00:58:39 UTC) #53
dpapad
LGTM webui
3 years, 6 months ago (2017-06-20 01:10:05 UTC) #54
Lei Zhang
lgtm with no new OS_IOS bits added.
3 years, 6 months ago (2017-06-20 01:26:59 UTC) #55
rbpotter
https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc File chrome/browser/policy/configuration_policy_handler_list_factory.cc (right): https://codereview.chromium.org/2885363003/diff/160001/chrome/browser/policy/configuration_policy_handler_list_factory.cc#newcode621 chrome/browser/policy/configuration_policy_handler_list_factory.cc:621: #if !defined(OS_CHROMEOS) && !defined(OS_ANDROID) && !defined(OS_IOS) On 2017/06/20 00:56:25, ...
3 years, 6 months ago (2017-06-20 02:58:25 UTC) #56
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2885363003/180001
3 years, 6 months ago (2017-06-20 19:34:57 UTC) #63
commit-bot: I haz the power
3 years, 6 months ago (2017-06-20 19:42:09 UTC) #66
Message was sent while issue was closed.
Committed patchset #9 (id:180001) as
https://chromium.googlesource.com/chromium/src/+/421c21956a3d5da8406d3aacec9e...

Powered by Google App Engine
This is Rietveld 408576698