rem: if (prefs) { 
add: if (printService) { 
context: function onOK(){  var print_paper_size = 0;  if (prefs) {    if (dialog.fileRadio.checked == true) {      prefs.SetBoolPref("print.print_tofile", true);    } else {      prefs.SetBoolPref("print.print_tofile", false);    }    if (dialog.lastRadio.checked == true) {      prefs.SetBoolPref("print.print_reversed", true);    } else {      prefs.SetBoolPref("print.print_reversed", false);    }    if (dialog.colorRadio.checked == true) {      prefs.SetBoolPref("print.print_color", true);    } else {      prefs.SetBoolPref("print.print_color", false);    }    if (dialog.letterRadio.checked == true) {      print_paper_size = 0;    } else if (dialog.legalRadio.checked == true) {      print_paper_size = 1;    } else if (dialog.exectiveRadio.checked == true) {      print_paper_size = 2;    } else if (dialog.a4Radio.checked == true) {      print_paper_size = 3;    }    prefs.SetIntPref("print.print_paper_size", print_paper_size);    // save these out so they can be picked up by the device spec    prefs.SetIntPref("print.print_margin_top_js", dialog.topInput.value * 1000);    prefs.SetIntPref("print.print_margin_left_js", dialog.leftInput.value * 1000);    prefs.SetIntPref("print.print_margin_bottom_js", dialog.bottomInput.value *1000);    prefs.SetIntPref("print.print_margin_right_js", dialog.rightInput.value * 1000);    prefs.SetCharPref("print.print_command", dialog.cmdInput.value);    prefs.SetCharPref("print.print_file", dialog.fileInput.value);    prefs.SetBoolPref("print.print_allpagesrange", dialog.allpagesRadio.checked);    prefs.SetBoolPref("print.print_pagerange", dialog.rangeRadio.checked);    prefs.SetBoolPref("print.print_selectionrange", dialog.selectionRadio.checked);    prefs.SetIntPref("print.print_frompage", dialog.frompageInput.value);    prefs.SetIntPref("print.print_topage", dialog.topageInput.value);  }  if (param) {    param.SetInt(0, 0 );  }  return true;}
meta: 10234	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/10234/b71790af515a7683e58068b87502d0e171927e7a/printdialog.js/clean/xpfe/global/resources/content/unix/printdialog.js