Commit fbb82800 authored by scottmg's avatar scottmg Committed by Commit bot

Remove hidePrintWithSystemDialog disableability

Only used for Metro on Windows, which no longer exists.

R=dpapad@chromium.org
BUG=558054

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

Cr-Commit-Position: refs/heads/master@{#381803}
parent 1bbe2d3a
......@@ -481,7 +481,6 @@ cr.define('print_preview', function() {
var nativeInitialSettings = new print_preview.NativeInitialSettings(
initialSettings['printAutomaticallyInKioskMode'] || false,
initialSettings['appKioskMode'] || false,
initialSettings['hidePrintWithSystemDialogLink'] || false,
numberFormatSymbols[0] || ',',
numberFormatSymbols[1] || '.',
unitType,
......@@ -938,7 +937,6 @@ cr.define('print_preview', function() {
function NativeInitialSettings(
isInKioskAutoPrintMode,
isInAppKioskMode,
hidePrintWithSystemDialogLink,
thousandsDelimeter,
decimalDelimeter,
unitType,
......@@ -964,13 +962,6 @@ cr.define('print_preview', function() {
*/
this.isInAppKioskMode_ = isInAppKioskMode;
/**
* Whether we should hide the link which shows the system print dialog.
* @type {boolean}
* @private
*/
this.hidePrintWithSystemDialogLink_ = hidePrintWithSystemDialogLink;
/**
* Character delimeter of thousands digits.
* @type {string}
......@@ -1059,14 +1050,6 @@ cr.define('print_preview', function() {
return this.isInAppKioskMode_;
},
/**
* @return {boolean} Whether we should hide the link which shows the
system print dialog.
*/
get hidePrintWithSystemDialogLink() {
return this.hidePrintWithSystemDialogLink_;
},
/** @return {string} Character delimeter of thousands digits. */
get thousandsDelimeter() {
return this.thousandsDelimeter_;
......
......@@ -651,8 +651,7 @@ cr.define('print_preview', function() {
this.appState_.setInitialized();
$('document-title').innerText = settings.documentTitle;
this.hideSystemDialogLink_ = settings.hidePrintWithSystemDialogLink ||
settings.isInAppKioskMode;
this.hideSystemDialogLink_ = settings.isInAppKioskMode;
if ($('system-dialog-link')) {
setIsVisible($('system-dialog-link'),
this.shouldShowSystemDialogLink_());
......
......@@ -167,9 +167,6 @@ const char kPrintAutomaticallyInKioskMode[] = "printAutomaticallyInKioskMode";
const char kAppKioskMode[] = "appKioskMode";
// Dictionary field to store Cloud Print base URL.
const char kCloudPrintUrl[] = "cloudPrintUrl";
#if defined(OS_WIN)
const char kHidePrintWithSystemDialogLink[] = "hidePrintWithSystemDialogLink";
#endif
// Name of a dictionary field holding the state of selection for document.
const char kDocumentHasSelection[] = "documentHasSelection";
// Dictionary field holding the default destination selection rules.
......@@ -1293,13 +1290,6 @@ void PrintPreviewHandler::SendInitialSettings(
cmdline->HasSwitch(switches::kKioskModePrinting));
initial_settings.SetBoolean(kAppKioskMode,
chrome::IsRunningInForcedAppMode());
#if defined(OS_WIN)
// In Win8 metro, the system print dialog can only open on the desktop. Doing
// so will cause the browser to appear hung, so we don't show the link in
// metro.
bool is_ash = (chrome::GetActiveDesktop() == chrome::HOST_DESKTOP_TYPE_ASH);
initial_settings.SetBoolean(kHidePrintWithSystemDialogLink, is_ash);
#endif
if (prefs) {
const std::string rules_str =
prefs->GetString(prefs::kPrintPreviewDefaultDestinationSelectionRules);
......
......@@ -172,7 +172,6 @@ PrintPreviewWebUITest.prototype = {
this.initialSettings_ = new print_preview.NativeInitialSettings(
false /*isInKioskAutoPrintMode*/,
false /*isInAppKioskMode*/,
false /*hidePrintWithSystemDialogLink*/,
',' /*thousandsDelimeter*/,
'.' /*decimalDelimeter*/,
1 /*unitType*/,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment