rem: var pref = Components.classes["@mozilla.org/preferences-service;1"] .getService(Components.interfaces.nsIPrefBranch); if (pref) { gUseGlobalPrintSettings = pref.getBoolPref("print.use_global_printsettings", false); }  var printOptionsService = Components.classes["@mozilla.org/gfx/printoptions;1"] .getService(Components.interfaces.nsIPrintOptions);   if (gPrintSettings == null) { gPrintSettings = printOptionsService.CreatePrintSettings(); }    if (gUseGlobalPrintSettings) { gPrintSettings = printOptionsService.printSettingsValues; 
add: var ifreq = _content.QueryInterface(Components.interfaces.nsIInterfaceRequestor); var webBrowserPrint = ifreq.getInterface(Components.interfaces.nsIWebBrowserPrint); if (webBrowserPrint) { gPrintSettings = GetPrintSettings(webBrowserPrint); 
context: function BrowserPrintSetup(){  try {    var pref = Components.classes["@mozilla.org/preferences-service;1"]                         .getService(Components.interfaces.nsIPrefBranch);    if (pref) {      gUseGlobalPrintSettings = pref.getBoolPref("print.use_global_printsettings", false);    }    var printOptionsService = Components.classes["@mozilla.org/gfx/printoptions;1"]                                           .getService(Components.interfaces.nsIPrintOptions);    // create our own local copy of the print settings    if (gPrintSettings == null) {      gPrintSettings = printOptionsService.CreatePrintSettings();    }    // if we are using the global settings then get them     // before calling page setup    if (gUseGlobalPrintSettings) {      gPrintSettings = printOptionsService.printSettingsValues;    }    goPageSetup(gPrintSettings);  // from utilityOverlay.js    // now set our setting into the global settings    // after the changes were made    if (gUseGlobalPrintSettings) {      printOptionsService.printSettingsValues = gPrintSettings;    }  } catch (e) {    alert("BrowserPrintSetup "+e);  }}
meta: 5459	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/5459/9658379654be61450ad8e0fb7bd60e4caa5c05c7/browser.js/clean/suite/browser/browser.js