add: var print_orientation; 
context: function onOK(){  var print_paper_size = 0;  if (printService) {    var print_howToEnableUI = gPrintOptInterface.kFrameEnableNone;    printService.printToFile   = dialog.fileRadio.checked;    printService.printReversed = dialog.lastRadio.checked;    printService.printInColor  = dialog.colorRadio.checked;    print_howToEnableUI        = printService.howToEnableFrameUI;    if (dialog.letterRadio.checked) {      print_paper_size = gPrintOptInterface.kLetterPaperSize;    } else if (dialog.legalRadio.checked) {      print_paper_size = gPrintOptInterface.kLegalPaperSize;    } else if (dialog.exectiveRadio.checked) {      print_paper_size = gPrintOptInterface.kExecutivePaperSize;    } else if (dialog.a4Radio.checked) {      print_paper_size = gPrintOptInterface.kA4PaperSize;    } else if (dialog.a3Radio.checked) {      print_paper_size = gPrintOptInterface.kA3PaperSize;    }    printService.paperSize = print_paper_size;        if (dialog.portraitRadio.checked) {      print_orientation = gPrintOptInterface.kPortraitOrientation;    } else if (dialog.landscapeRadio.checked) {      print_orientation = gPrintOptInterface.kLandscapeOrientation;    }    printService.orientation = print_orientation;    // save these out so they can be picked up by the device spec    printService.marginTop    = dialog.topInput.value;    printService.marginLeft   = dialog.leftInput.value;    printService.marginBottom = dialog.bottomInput.value;    printService.marginRight  = dialog.rightInput.value;    printService.printCommand = dialog.cmdInput.value;    printService.toFileName   = dialog.fileInput.value;    if (dialog.allpagesRadio.checked) {      printService.printRange = gPrintOptInterface.kRangeAllPages;    } else if (dialog.rangeRadio.checked) {      printService.printRange = gPrintOptInterface.kRangeSpecifiedPageRange;    } else if (dialog.selectionRadio.checked) {      printService.printRange = gPrintOptInterface.kRangeSelection;    }    printService.startPageRange = dialog.frompageInput.value;    printService.endPageRange   = dialog.topageInput.value;    var frametype = gPrintOptInterface.kNoFrames;    if (print_howToEnableUI != gPrintOptInterface.kFrameEnableNone) {      if (dialog.aslaidoutRadio.checked) {        frametype = gPrintOptInterface.kFramesAsIs;      } else if (dialog.selectedframeRadio.checked) {        frametype = gPrintOptInterface.kSelectedFrame;      } else if (dialog.eachframesepRadio.checked) {        frametype = gPrintOptInterface.kEachFrameSep;      } else {        frametype = gPrintOptInterface.kSelectedFrame;      }    }    printService.printFrameType = frametype;  } else {    dump("************ printService: "+printService+"\n");  }  if (param) {    param.SetInt(0, 0 );  }  return true;}
meta: 10234	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/10234/19cbf2a87edf456bfeda3e2c3e2a9d0d8401498a/printdialog.js/clean/xpfe/global/resources/content/unix/printdialog.js