rem stringlengths 0 126k | add stringlengths 0 441k | context stringlengths 15 136k |
|---|---|---|
if ( lastInput && lastInput.input.value ) | if ( lastInput && lastInput.value ) | function awClickEmptySpace(targ, setFocus){ if (targ.localName != 'treechildren') return; dump("awClickEmptySpace\n"); var lastInput = awGetInputElement(top.MAX_RECIPIENTS); if ( lastInput && lastInput.input.value ) awAppendNewRow(setFocus); else if (setFocus) awSetFocus(top.MAX_RECIPIENTS, lastInput);} |
if ("localName" in targ && targ.localName != 'treechildren') | if (targ.localName != 'treechildren') | function awClickEmptySpace(targ, setFocus){ if ("localName" in targ && targ.localName != 'treechildren') return; dump("awClickEmptySpace\n"); var lastInput = awGetInputElement(top.MAX_RECIPIENTS); if ( lastInput && lastInput.value ) awAppendNewRow(setFocus); else if (setFocus) awSetFocus(top.MAX_RECI... |
dump("awClickEmptySpace\n"); | function awClickEmptySpace(targ, setFocus){ if ("localName" in targ && targ.localName != 'treechildren') return; dump("awClickEmptySpace\n"); var lastInput = awGetInputElement(top.MAX_RECIPIENTS); if ( lastInput && lastInput.value ) awAppendNewRow(setFocus); else if (setFocus) awSetFocus(top.MAX_RECI... | |
dump("awCopyNode\n"); var newNode = awCopyNodeAndChildren(node); | var newNode = node.cloneNode(true); | function awCopyNode(node, parentNode, beforeNode){ dump("awCopyNode\n"); // XXXwaterson Ideally, we'd just do this, but for bug 26528 // (and some of the funky logic about the 'id' attribute in // awCopyNodeAndChildren). // //var newNode = node.cloneNode(true); var newNode = awCopyNodeAndChi... |
return newNode; | function awCopyNode(node, parentNode, beforeNode){ dump("awCopyNode\n"); // XXXwaterson Ideally, we'd just do this, but for bug 26528 // (and some of the funky logic about the 'id' attribute in // awCopyNodeAndChildren). // //var newNode = node.cloneNode(true); var newNode = awCopyNodeAndChi... | |
inputElement.input.value = ""; | inputElement.value = ""; | function awDeleteHit(inputElement){ var row = awGetRowByInputElement(inputElement); /* 1. don't delete the row if it's the last one remaining, just reset it! */ if (top.MAX_RECIPIENTS <= 1) { inputElement.input.value = ""; return; } /* 2. Set the focus to the previous field if possible */ if (row > 1) ... |
awRemoveRow(row); | awCleanupRows(row); | function awDeleteHit(inputElement){ var row = awGetRowByInputElement(inputElement); var nextRow = awGetInputElement(row+1); var index = 1; if (!nextRow) { nextRow = awGetInputElement(row-1); index = -1; } if (nextRow) { awSetFocus(row+index, nextRow) if (row) awRemoveRow(row); } else inputEl... |
msgCompose.ResetNodeEventHandlers(node); | gMsgCompose.ResetNodeEventHandlers(node); | function awFinishCopyNode(node){ msgCompose.ResetNodeEventHandlers(node); return;} |
var attributes = node.attributes; if ( attributes && attributes.length ) { var attrNode, name; for ( var index = 0; index < attributes.length; index++ ) { attrNode = attributes.item(index); name = attrNode.nodeName; if (name.substring(0, 2) == 'on') { node.setAttribute(name, attrNode.nodeValue); } } } if ( node.chi... | msgCompose.ResetNodeEventHandlers(node); return; | function awFinishCopyNode(node){// dump ("awFinishCopyNode, node name=" + node.nodeName + "\n"); // Because event handler attributes set into a node before this node is inserted // into the DOM are not recognised (in fact not compiled), we need to parsed again // the whole node and reset event handlers. var attributes... |
for ( var row = 2; row <= top.MAX_RECIPIENTS; row++ ) awFinishCopyNode(awGetTreeRow(row)); | var treeChildren = document.getElementById('addressWidgetBody'); awFinishCopyNode(treeChildren); | function awFinishCopyNodes(){ for ( var row = 2; row <= top.MAX_RECIPIENTS; row++ ) awFinishCopyNode(awGetTreeRow(row));} |
var treerow = awGetTreeRow(row); if ( treerow ) { var input = treerow.getElementsByTagName('INPUT'); if ( input && input.length == 1 ) return input[0]; } return 0; | return document.getElementById("msgRecipient#" + row); | function awGetInputElement(row){ var treerow = awGetTreeRow(row); if ( treerow ) { var input = treerow.getElementsByTagName('INPUT'); if ( input && input.length == 1 ) return input[0]; } return 0;} |
var treerow = awGetTreeRow(row); if ( treerow ) { var popup = treerow.getElementsByTagName('SELECT'); if ( popup && popup.length == 1 ) return popup[0]; } return 0; | return document.getElementById("msgRecipientType#" + row); | function awGetPopupElement(row){ var treerow = awGetTreeRow(row); if ( treerow ) { var popup = treerow.getElementsByTagName('SELECT'); if ( popup && popup.length == 1 ) return popup[0]; } return 0;} |
if ( lastInput && lastInput.input.value && !top.doNotCreateANewRow) | if ( lastInput && lastInput.value && !top.doNotCreateANewRow) | function awInputChanged(inputElement){ dump("awInputChanged\n");// AutoCompleteAddress(inputElement); //Do we need to add a new row? var lastInput = awGetInputElement(top.MAX_RECIPIENTS); if ( lastInput && lastInput.input.value && !top.doNotCreateANewRow) awAppendNewRow(false); top.doNotCreateANewRow = false;} |
dump("awInputChanged\n"); | function awInputChanged(inputElement){ dump("awInputChanged\n");// AutoCompleteAddress(inputElement); //Do we need to add a new row? var lastInput = awGetInputElement(top.MAX_RECIPIENTS); if ( lastInput && lastInput.value && !top.doNotCreateANewRow) awAppendNewRow(false); top.doNotCreateANewRow = false;} | |
inputElementType = document.getElementById("msgRecipient#1").nodeName; | inputElementType = document.getElementById("msgRecipient#1").localName; | function awInputElementName(){ if (inputElementType == "") inputElementType = document.getElementById("msgRecipient#1").nodeName; return inputElementType;} |
inputElementType = document.getElementById("address#1").nodeName; | inputElementType = document.getElementById("address#1").localName; | function awInputElementName(){ if (inputElementType == "") inputElementType = document.getElementById("address#1").nodeName; return inputElementType;} |
event.preventBubble(); | event.stopPropagation(); | function awNotAnEmptyArea(event){ //This is temporary until i figure out how to ensure to always having an empty space after the last row var lastInput = awGetInputElement(top.MAX_RECIPIENTS); if ( lastInput && lastInput.value ) awAppendNewRow(false); event.preventBubble();} |
dump("awNotAnEmptyArea\n"); | function awNotAnEmptyArea(event){ //This is temporary until i figure out how to ensure to always having an empty space after the last row dump("awNotAnEmptyArea\n"); var lastInput = awGetInputElement(top.MAX_RECIPIENTS); if ( lastInput && lastInput.value ) awAppendNewRow(false); event.preventBubble();} | |
try { if (!gPromptService) { gPromptService = Components.classes[ "@mozilla.org/embedcomp/prompt-service;1"].getService(). QueryInterface(Components.interfaces.nsIPromptService); } } catch (ex) { } | function awRecipientErrorCommand(errItem, element){ // remove the angle brackets from the general error message to construct // the title for the alert. someday we'll pass this info using a real // exception object, and then this code can go away. // var generalErrString; if (errItem.value != "") { ... | |
if (!element.input.value) | if (!element.value) | function awRecipientKeyDown(event, element){ switch(event.keyCode) { case 46: case 8: if (!element.input.value) awDeleteHit(element); event.preventBubble(); //We need to stop the event else the tree will receive it and the function //awKeyDown will be executed! break; }} |
event.preventBubble(); | event.stopPropagation(); | function awRecipientKeyDown(event, element){ switch(event.keyCode) { case 46: case 8: /* do not query directly the value of the text field else the autocomplete widget could potentially alter it value while doing some internal cleanup, instead, query the value through the first child */ if (!element.v... |
return; | function awRecipientKeyPress(event, element){ switch(event.keyCode) { case KeyEvent.DOM_VK_UP: awArrowHit(element, -1); break; case KeyEvent.DOM_VK_DOWN: awArrowHit(element, 1); break; case KeyEvent.DOM_VK_RETURN: case KeyEvent.DOM_VK_TAB: { // if the user text contains a comma or a line return, ig... | |
else if (event.keyCode == KeyEvent.DOM_VK_TAB) awTabFromRecipient(element, event); | function awRecipientKeyPress(event, element){ switch(event.keyCode) { case KeyEvent.DOM_VK_UP: awArrowHit(element, -1); break; case KeyEvent.DOM_VK_DOWN: awArrowHit(element, 1); break; case KeyEvent.DOM_VK_RETURN: case KeyEvent.DOM_VK_TAB: { // if the user text contains a comma or a line return, ig... | |
} case 9: awTabFromRecipient(element, event); break; | } | function awRecipientKeyPress(event, element){ switch(event.keyCode) { case KeyEvent.DOM_VK_UP: awArrowHit(element, -1); break; case KeyEvent.DOM_VK_DOWN: awArrowHit(element, 1); break; case KeyEvent.DOM_VK_RETURN: case KeyEvent.DOM_VK_TAB: { // if the user text contains a comma or a line return, ig... |
if (input.input.value == recipientArray.StringAt(index)) | if (input.value == recipientArray.StringAt(index)) | function awRemoveRecipients(msgCompFields, recipientType, recipientsList){ if (!msgCompFields) return; var recipientArray = msgCompFields.SplitRecipients(recipientsList, false); if (! recipientArray) return; for ( var index = 0; index < recipientArray.count; index++ ) for (var row = 1; row <= top.MAX_REC... |
if ( inputElement.input.value ) | if ( inputElement.value ) | function awReturnHit(inputElement){ var row = awGetRowByInputElement(inputElement); var nextInput = awGetInputElement(row+1); if ( !nextInput ) { if ( inputElement.input.value ) awAppendNewRow(true); else // No adress entered, switch to Subject field { var subjectField = document.getElementById( 'msgSubj... |
dump("***** awReturnHit\n"); | function awReturnHit(inputElement){ dump("***** awReturnHit\n"); var row = awGetRowByInputElement(inputElement); if ( inputElement.value ) { var nextInput = awGetInputElement(row+1); if ( !nextInput ) awAppendNewRow(true); else awSetFocus(row+1, nextInput); }} | |
selectElementType = document.getElementById("msgRecipientType#1").nodeName; | selectElementType = document.getElementById("msgRecipientType#1").localName; | function awSelectElementName(){ if (selectElementType == "") selectElementType = document.getElementById("msgRecipientType#1").nodeName; return selectElementType;} |
return; | function awSetFocus(row, inputElement){ return; top.awRow = row; top.awInputElement = inputElement; top.awFocusRetry = 0; setTimeout("_awSetFocus();", 0);} | |
function awSetInputAndPopup(firstRow, inputValue, popupValue) | function awSetInputAndPopup(inputValue, popupValue, parentNode, templateNode) | function awSetInputAndPopup(firstRow, inputValue, popupValue){ var row = firstRow; if ( inputValue && popupValue ) { var addressArray = inputValue.split(","); for ( var index = 0; index < addressArray.length; index++ ) { // remove leading spaces while ( addressArray[index][0] == " " ) addressArray[index] ... |
var row = firstRow; | function awSetInputAndPopup(firstRow, inputValue, popupValue){ var row = firstRow; if ( inputValue && popupValue ) { var addressArray = inputValue.split(","); for ( var index = 0; index < addressArray.length; index++ ) { // remove leading spaces while ( addressArray[index][0] == " " ) addressArray[index] ... | |
{ while ( addressArray[index][0] == " " ) addressArray[index] = addressArray[index].substring(1, addressArray[index].length); if ( row == (top.MAX_RECIPIENTS + 1)) { var body = document.getElementById('addressWidgetBody'); awCopyNode(awGetTreeItem(1), body, 0); top.MAX_RECIPIENTS++; } if ( row <= top.MAX_RECIPIENT... | _awSetInputAndPopup(addressArray[index], popupValue, parentNode, templateNode); | function awSetInputAndPopup(firstRow, inputValue, popupValue){ var row = firstRow; if ( inputValue && popupValue ) { var addressArray = inputValue.split(","); for ( var index = 0; index < addressArray.length; index++ ) { // remove leading spaces while ( addressArray[index][0] == " " ) addressArray[index] ... |
return(firstRow); | function awSetInputAndPopup(firstRow, inputValue, popupValue){ var row = firstRow; if ( inputValue && popupValue ) { var addressArray = inputValue.split(","); for ( var index = 0; index < addressArray.length; index++ ) { // remove leading spaces while ( addressArray[index][0] == " " ) addressArray[index] ... | |
_awSetInputAndPopup(inputArray.StringAt(index), popupValue, parentNode, templateNode); | { recipient = null; if (gMimeHeaderParser) try { recipient = gMimeHeaderParser.unquotePhraseOrAddrWString(inputArray.StringAt(index), true); } catch (ex) {}; if (!recipient) recipient = inputArray.StringAt(index) _awSetInputAndPopup(recipient, popupValue, parentNode, templateNode); } | function awSetInputAndPopupFromArray(inputArray, popupValue, parentNode, templateNode){ if ( inputArray && popupValue ) { for ( var index = 0; index < inputArray.count; index++ ) _awSetInputAndPopup(inputArray.StringAt(index), popupValue, parentNode, templateNode); }} |
function awSetInputAndPopupFromArray(firstRow, inputArray, popupValue) | function awSetInputAndPopupFromArray(inputArray, popupValue, parentNode, templateNode) | function awSetInputAndPopupFromArray(firstRow, inputArray, popupValue){ var row = firstRow; if ( inputArray && popupValue ) { for ( var index = 0; index < inputArray.count; index++ ) { // remove leading spaces inputValue = inputArray.StringAt(index); while ( inputValue[0] == " " ) inputValue = inputValue.s... |
var row = firstRow; | function awSetInputAndPopupFromArray(firstRow, inputArray, popupValue){ var row = firstRow; if ( inputArray && popupValue ) { for ( var index = 0; index < inputArray.count; index++ ) { // remove leading spaces inputValue = inputArray.StringAt(index); while ( inputValue[0] == " " ) inputValue = inputValue.s... | |
{ inputValue = inputArray.StringAt(index); while ( inputValue[0] == " " ) inputValue = inputValue.substring(1, inputValue.length); if ( row == (top.MAX_RECIPIENTS + 1)) { var body = document.getElementById('addressWidgetBody'); awCopyNode(awGetTreeItem(1), body, 0); top.MAX_RECIPIENTS++; } if ( row <= top.MAX_RECI... | _awSetInputAndPopup(inputArray.StringAt(index), popupValue, parentNode, templateNode); | function awSetInputAndPopupFromArray(firstRow, inputArray, popupValue){ var row = firstRow; if ( inputArray && popupValue ) { for ( var index = 0; index < inputArray.count; index++ ) { // remove leading spaces inputValue = inputArray.StringAt(index); while ( inputValue[0] == " " ) inputValue = inputValue.s... |
return(firstRow); | function awSetInputAndPopupFromArray(firstRow, inputArray, popupValue){ var row = firstRow; if ( inputArray && popupValue ) { for ( var index = 0; index < inputArray.count; index++ ) { // remove leading spaces inputValue = inputArray.StringAt(index); while ( inputValue[0] == " " ) inputValue = inputValue.s... | |
this.prefPart1 = "security.xpconnect.activex."; this.prefPart2 = ".hosting_flags"; this.globalPrefName = this.prefPart1 + "global" + this.prefPart2; | addPrefListener(this, kGlobalHostingFlagsPref); | function AxSecurityPolicy(){ this.prefPart1 = "security.xpconnect.activex."; this.prefPart2 = ".hosting_flags"; this.globalPrefName = this.prefPart1 + "global" + this.prefPart2; // TODO read from prefs // addPrefListener(this, this.globalPrefName); this.syncPrefs();} |
this.globalHostingFlags = kDefaultGlobalHostingFlags; | function AxSecurityPolicy(){ this.prefPart1 = "security.xpconnect.activex."; this.prefPart2 = ".hosting_flags"; this.globalPrefName = this.prefPart1 + "global" + this.prefPart2; // TODO read from prefs // addPrefListener(this, this.globalPrefName); this.syncPrefs();} | |
var out = "", bits, i, j; | function b64(aBytes) { const B64_CHARS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; var out = "", bits, i, j; while (aBytes.length >= 3) { bits = 0; for (i = 0; i < 3; i++) { bits <<= 8; bits |= aBytes[i]; } for (j = 18; j >= 0; j -= 6) out += B64_CHARS[... | |
while (aBytes.length >= 3) { bits = 0; for (i = 0; i < 3; i++) { bits <<= 8; bits |= aBytes[i]; } for (j = 18; j >= 0; j -= 6) out += B64_CHARS[(bits>>j) & 0x3F]; | var index = 0; function get3Bytes() { if (aBytes.length - index < 3) return null; | function b64(aBytes) { const B64_CHARS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; var out = "", bits, i, j; while (aBytes.length >= 3) { bits = 0; for (i = 0; i < 3; i++) { bits <<= 8; bits |= aBytes[i]; } for (j = 18; j >= 0; j -= 6) out += B64_CHARS[... |
aBytes.splice(0, 3); | return aBytes.slice(index, index += 3); | function b64(aBytes) { const B64_CHARS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; var out = "", bits, i, j; while (aBytes.length >= 3) { bits = 0; for (i = 0; i < 3; i++) { bits <<= 8; bits |= aBytes[i]; } for (j = 18; j >= 0; j -= 6) out += B64_CHARS[... |
switch (aBytes.length) { | var out = ""; var bytes = null; while ((bytes = get3Bytes())) { var bits = 0; for (var i = 0; i < 3; i++) { bits <<= 8; bits |= bytes[i]; } for (var j = 18; j >= 0; j -= 6) out += B64_CHARS[(bits>>j) & 0x3F]; } bytes = aBytes.slice(index); switch (bytes.length) { | function b64(aBytes) { const B64_CHARS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; var out = "", bits, i, j; while (aBytes.length >= 3) { bits = 0; for (i = 0; i < 3; i++) { bits <<= 8; bits |= aBytes[i]; } for (j = 18; j >= 0; j -= 6) out += B64_CHARS[... |
out += B64_CHARS[(aBytes[0]>>2) & 0x3F]; out += B64_CHARS[((aBytes[0] & 0x03) << 4) | ((aBytes[1] >> 4) & 0x0F)]; out += B64_CHARS[((aBytes[1] & 0x0F) << 2)]; out += "="; | out += B64_CHARS[(bytes[0]>>2) & 0x3F] + B64_CHARS[((bytes[0] & 0x03) << 4) | ((bytes[1] >> 4) & 0x0F)] + B64_CHARS[((bytes[1] & 0x0F) << 2)] + "="; | function b64(aBytes) { const B64_CHARS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; var out = "", bits, i, j; while (aBytes.length >= 3) { bits = 0; for (i = 0; i < 3; i++) { bits <<= 8; bits |= aBytes[i]; } for (j = 18; j >= 0; j -= 6) out += B64_CHARS[... |
out += B64_CHARS[(aBytes[0]>>2) & 0x3F]; out += B64_CHARS[(aBytes[0] & 0x03) << 4]; out += "=="; | out += B64_CHARS[(bytes[0]>>2) & 0x3F] + B64_CHARS[(bytes[0] & 0x03) << 4] + "=="; | function b64(aBytes) { const B64_CHARS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; var out = "", bits, i, j; while (aBytes.length >= 3) { bits = 0; for (i = 0; i < 3; i++) { bits <<= 8; bits |= aBytes[i]; } for (j = 18; j >= 0; j -= 6) out += B64_CHARS[... |
if (categoryNameFix == parent.backupPrefList[i].name) | if (categoryNameFix == parent.backupPrefList[i].name) { | backupData: function (categoryNameFix) { var currentColor; try { currentColor = categoryPrefBranch.getCharPref(categoryNameFix); } catch (ex) { currentColor="##NEW"; } for (var i=0; i < parent.backupPrefList.length; i++) { if (categoryNameFix == pa... |
} | backupData: function (categoryNameFix) { var currentColor; try { currentColor = categoryPrefBranch.getCharPref(categoryNameFix); } catch (ex) { currentColor="##NEW"; } for (var i=0; i < parent.backupPrefList.length; i++) { if (categoryNameFix == pa... | |
for (var i in data) { | for (var i = 0; i < data.length; i++) { | function base64ToString(data) { var result = ''; var leftbits = 0; // number of bits decoded, but yet to be appended var leftdata = 0; // bits decoded, bt yet to be appended // Convert one by one. for (var i in data) { var c = toBinaryTable[data.charCodeAt(i) & 0x7f]; var padding = (data[i]... |
this._transport = this._sockService.createTransport (host, port, null, -1, | var pps = Components.classes["@mozilla.org/network/protocol-proxy-service;1"]. getService(). QueryInterface(Components.interfaces.nsIProtocolProxyService); if (!pps) throw ("Couldn't get protocol proxy service"); var uri = Components.classes["@mozilla.org/network/simple-uri;1"]. createInstance(Components.interfaces.n... | function bc_connect(host, port, bind, tcp_flag, observer){ if (typeof tcp_flag == "undefined") tcp_flag = false; this.host = host.toLowerCase(); this.port = port; this.bind = bind; this.tcp_flag = tcp_flag; this._transport = this._sockService.createTransport (host, port, null, -1, ... |
this.hashes = {}; | beforeUnSelect: function() { searchView.destroyHandlers(); }, | |
var installLog = this._getInstallLogFile(); | begin: function() { var installLog = this._getInstallLogFile(); var updateLog = this._getUpdateLogFile(); if (!installLog || !updateLog) return; var entries = { dirs: [], files: [] }; this._readUpdateLog(updateLog, entries); this._outputStream = openFileOutputStream(installLog, PR_WRONLY... | |
if (!installLog || !updateLog) | if (!updateLog) | begin: function() { var installLog = this._getInstallLogFile(); var updateLog = this._getUpdateLogFile(); if (!installLog || !updateLog) return; var entries = { dirs: [], files: [] }; this._readUpdateLog(updateLog, entries); this._outputStream = openFileOutputStream(installLog, PR_WRONLY... |
var entries = { dirs: [], files: [] }; this._readUpdateLog(updateLog, entries); | var newEntries = { }; this._readUpdateLog(updateLog, newEntries); try { const nsIDirectoryEnumerator = Components.interfaces.nsIDirectoryEnumerator; const nsILocalFile = Components.interfaces.nsILocalFile; var prefixWizLog = "install_wizard"; var uninstallDir = getFile(KEY_APPDIR); uninstallDir.append("uninstall"); va... | begin: function() { var installLog = this._getInstallLogFile(); var updateLog = this._getUpdateLogFile(); if (!installLog || !updateLog) return; var entries = { dirs: [], files: [] }; this._readUpdateLog(updateLog, entries); this._outputStream = openFileOutputStream(installLog, PR_WRONLY... |
openFileOutputStream(installLog, PR_WRONLY | PR_APPEND); this._writeLine("\nUPDATE [" + new Date().toUTCString() + "]"); | openFileOutputStream(uninstallLog, PR_WRONLY | PR_APPEND); | begin: function() { var installLog = this._getInstallLogFile(); var updateLog = this._getUpdateLogFile(); if (!installLog || !updateLog) return; var entries = { dirs: [], files: [] }; this._readUpdateLog(updateLog, entries); this._outputStream = openFileOutputStream(installLog, PR_WRONLY... |
var i; for (i = 0; i < entries.dirs.length; ++i) this._writeLine(PREFIX_CREATE_FOLDER + entries.dirs[i]); for (i = 0; i < entries.files.length; ++i) this._writeLine(PREFIX_INSTALLING + entries.files[i]); | for (var relPath in newEntries) this._writeLine(PREFIX_FILE + relPath); | begin: function() { var installLog = this._getInstallLogFile(); var updateLog = this._getUpdateLogFile(); if (!installLog || !updateLog) return; var entries = { dirs: [], files: [] }; this._readUpdateLog(updateLog, entries); this._outputStream = openFileOutputStream(installLog, PR_WRONLY... |
if ( domselection && !domselection.isCollapsed) | if ( domselection && !domselection.isCollapsed && domselection.containsNode(event.target,false)) | function BeginDragContentArea ( event ){ if ( event.target == null ) return; var dragService = Components.classes["component://netscape/widget/dragservice"].getService(Components.interfaces.nsIDragService); if ( dragService == null ) return; var trans = Components.classes["component://netscape/widget/transfer... |
for ( var i = 0; i < count; ++i ) { | for (i = 0; i < count; ++i ) { | function BeginDragOutliner(event, outliner, flavor){ if (event.target == outliner) { return(true); // continue propagating the event } if (!outliner) { return(false); } var dragStarted = false; var transArray = Components.classes["@mozilla.org/supports-array;1"].createInstance(Components.inter... |
var nsIDragService = Components.interfaces.nsIDragService; | function BeginDragOutliner(event, outliner, flavor){ if (event.target == outliner) { return(true); // continue propagating the event } if (!outliner) { return(false); } var dragStarted = false; var transArray = Components.classes["@mozilla.org/supports-array;1"].createInstance(Components.inter... | |
var childWithDatabase = tree; if ( ! childWithDatabase ) return(false); | function BeginDragResultTree(event){ debugDump("BeginDragResultTree\n"); //XXX we rely on a capturer to already have determined which item the mouse was over //XXX and have set an attribute. // if the click is on the tree proper, ignore it. We only care about clicks on items. if (event.target.localName != "treec... | |
var database = childWithDatabase.database; var rdf = GetRDFService(); if ((!rdf) || (!database)) { debugDump("CAN'T GET DATABASE\n"); return(false); } | function BeginDragResultTree(event){ debugDump("BeginDragResultTree\n"); //XXX we rely on a capturer to already have determined which item the mouse was over //XXX and have set an attribute. // if the click is on the tree proper, ignore it. We only care about clicks on items. if (event.target.localName != "treec... | |
if ( event.target == tree ) | if ( event.target == tree || event.target.localName == "treechildren" ) | function BeginDragTree ( event ){ //XXX we rely on a capturer to already have determined which item the mouse was over //XXX and have set an attribute. // if the click is on the tree proper, ignore it. We only care about clicks on items. var tree = document.getElementById("bookmarksTree"); if ( event.target ==... |
var nsIDragService = Components.interfaces.nsIDragService; | function BeginDragTree(event, tree, flavor){ if ( event.target == tree ) return(true); // continue propagating the event var treeItem = event.target.parentNode.parentNode; if (!treeItem) return(false); var childWithDatabase = tree; if ( ! childWithDatabase ) return(false); var... | |
var dragService = Components.classes["component: if ( !dragService ) return(false); | function BeginDragTree ( event ){ if ( !gDragDropEnabled ) return; //XXX we rely on a capturer to already have determined which item the mouse was over //XXX and have set an attribute. // if the click is on the tree proper, ignore it. We only care about clicks on items. var tree = document.getElementByI... | |
var id = event.target.parentNode.parentNode.getAttribute("id"); genData.data = id; genTextData.data = id; debug("ID: " + id); | var id = event.target.parentNode.parentNode.getAttribute("ref"); if (!id || id=="") { id = event.target.parentNode.parentNode.getAttribute("id"); } dump("\n ID: " + id); var parentID = event.target.parentNode.parentNode.parentNode.parentNode.getAttribute("ref"); if (!parentID || parentID == "") { parentID = event.t... | function BeginDragTree ( event ){ if ( !gDragDropEnabled ) return; //XXX we rely on a capturer to already have determined which item the mouse was over //XXX and have set an attribute. // if the click is on the tree proper, ignore it. We only care about clicks on items. var tree = document.getElementByI... |
debug("Type: '" + target + "'"); | dump(" Type: '" + target + "'"); | function BeginDragTree ( event ){ if ( !gDragDropEnabled ) return; //XXX we rely on a capturer to already have determined which item the mouse was over //XXX and have set an attribute. // if the click is on the tree proper, ignore it. We only care about clicks on items. var tree = document.getElementByI... |
trans.setTransferData ( "text/unicode", genData, id.length * 2); | dump("genData is " + genData.data + " len is " + genData.data.length + "\n"); trans.setTransferData ( "moz/rdfitem", genData, genData.data.length * 2); trans.setTransferData ( "text/unicode", genDataURL, genDataURL.data.length * 2); | function BeginDragTree ( event ){ if ( !gDragDropEnabled ) return; //XXX we rely on a capturer to already have determined which item the mouse was over //XXX and have set an attribute. // if the click is on the tree proper, ignore it. We only care about clicks on items. var tree = document.getElementByI... |
gBookmarksShell = new BookmarksToolbar("innermostBox"); | gBookmarksShell = new BookmarksToolbar("NC:PersonalToolbarFolder"); | function BM_navigatorLoad(aEvent){ if (!gBookmarksShell) { gBookmarksShell = new BookmarksToolbar("innermostBox"); controllers.appendController(gBookmarksShell.controller); removeEventListener("load", BM_navigatorLoad, false); }} |
function BogusChannel(URI) | function BogusChannel(URI, isSecure) | function BogusChannel(URI){ this.URI = URI; this.originalURI = URI;} |
this.isSecure = isSecure; | function BogusChannel(URI){ this.URI = URI; this.originalURI = URI;} | |
this.txmgr = BookmarksUtils.getTransactionManager(); | function BookmarkImportTransaction (aAction){ this.wrappedJSObject = this; this.txmgr = BookmarksUtils.getTransactionManager(); this.type = "import"; this.action = aAction; this.item = []; this.parent = []; this.index = []; this.isValid = [];} | |
this.txmgr = BookmarksUtils.getTransactionManager(); | function BookmarkInsertTransaction (aAction){ this.wrappedJSObject = this; this.txmgr = BookmarksUtils.getTransactionManager(); this.type = "insert"; this.action = aAction; this.item = null; this.parent = null; this.index = null; this.isValid = null;} | |
this.txmgr = BookmarksUtils.getTransactionManager(); | function BookmarkMoveTransaction (aAction, aSelection, aTarget){ this.wrappedJSObject = this; this.txmgr = BookmarksUtils.getTransactionManager(); this.type = "move"; this.action = aAction; this.selection = aSelection; this.target = aTarget; this.isValid = aSelection.isValid;} | |
var treeNode = document.getElementById('bookmarksTree'); var select_list = treeNode.selectedItems; if (select_list.length >= 1) { var type = select_list[0].getAttribute('type'); if (type != "http: { var props = window.open("chrome: "BookmarkProperties", "chrome, menubar"); props.BookmarkURL = select_list[0].getAttri... | var treeNode = document.getElementById('bookmarksTree'); var select_list = treeNode.selectedItems; if (select_list.length >= 1) { var type = select_list[0].getAttribute('type'); if (type != "http: { window.openDialog("chrome: "_blank", "chrome,menubar", select_list[0].getAttribute("id")); } } else { debug("nothing s... | function BookmarkProperties(){ var treeNode = document.getElementById('bookmarksTree');// var select_list = treeNode.getElementsByAttribute("selected", "true"); var select_list = treeNode.selectedItems; if (select_list.length >= 1) { // don't bother showing properties on bookmark separators var type = select_list[0].... |
this.txmgr = BookmarksUtils.getTransactionManager(); | function BookmarkRemoveTransaction (aAction){ this.wrappedJSObject = this; this.txmgr = BookmarksUtils.getTransactionManager(); this.type = "remove"; this.action = aAction; this.item = null; this.parent = null; this.index = null; this.isValid = null;} | |
gSearchTerms.booleanAnd = newBoolValue; | searchTerm.booleanAnd = newBoolValue; | function booleanChanged(event) { // when boolean changes, we have to update all the attributes on the // search terms var newBoolValue = (event.target.getAttribute("data") == "and") ? true : false; for (var i=0; i<gSearchTerms.length; i++) { var searchTerm = gSearchTerms[i]; gSearchTerm... |
this.scrollToRow(line - total / 2); | this.scrollToRow(line - (last - first + 1) / 2); | function bov_ctrln (line){ var first = this.tree.getFirstVisibleRow(); var last = this.tree.getLastVisibleRow(); this.scrollToRow(line - total / 2);} |
var ary = col.id.match (/:(.*)/); | if (typeof col == "object") col = col.id; var ary = col.match (/:(.*)/); | function bov_getcelltxt (row, col){ if (!this.columnNames) return ""; var ary = col.id.match (/:(.*)/); if (ary) col = ary[1]; var colName = this.columnNames[col]; if (typeof colName == "undefined") return ""; return this.data[row][colName];} |
var viz = last - first - headerRows; | var viz = last - first + 1 - headerRows; | function bov_scrollto (line, align){ if (!this.tree) return; var headerRows = 1; var first = this.tree.getFirstVisibleRow(); var last = this.tree.getLastVisibleRow(); var viz = last - first - headerRows; /* total number of visible rows */ /* all rows are visible, nothing to scroll */... |
if (first == 0 && last > this.rowCount) | if (first == 0 && last >= this.rowCount) | function bov_scrollto (line, align){ if (!this.tree) return; var headerRows = 1; var first = this.tree.getFirstVisibleRow(); var last = this.tree.getLastVisibleRow(); var viz = last - first - headerRows; /* total number of visible rows */ /* all rows are visible, nothing to scroll */... |
if (line > this.rowCount) line = this.rowCount; | if (line >= this.rowCount) line = this.rowCount - 1; | function bov_scrollto (line, align){ if (!this.tree) return; var headerRows = 1; var first = this.tree.getFirstVisibleRow(); var last = this.tree.getLastVisibleRow(); var viz = last - first - headerRows; /* total number of visible rows */ /* all rows are visible, nothing to scroll */... |
if (line > lastCenterable) | if (line > half_viz) | function bov_scrollto (line, align){ if (!this.tree) return; var headerRows = 1; var first = this.tree.getFirstVisibleRow(); var last = this.tree.getLastVisibleRow(); var viz = last - first - headerRows; /* total number of visible rows */ /* all rows are visible, nothing to scroll */... |
function boxAppendLabeledDateTime(box, labelProperty, date, isAllDay ) | function boxAppendLabeledDateTime(box, labelProperty, date) | function boxAppendLabeledDateTime(box, labelProperty, date, isAllDay ){ var jsDate = new Date(date.getTime()); var formattedDateTime = gCalendarWindow.dateFormater.formatDateTime( jsDate, true, isAllDay ); boxAppendLabeledText(box, labelProperty, formattedDateTime);} |
var jsDate = new Date(date.getTime()); var formattedDateTime = gCalendarWindow.dateFormater.formatDateTime( jsDate, true, isAllDay ); | var dateFormatter = Components.classes["@mozilla.org/calendar/datetime-formatter;1"] .getService(Components.interfaces.calIDateTimeFormatter); date = date.getInTimezone(calendarDefaultTimezone()); var formattedDateTime = dateFormatter.formatDateTime(date); | function boxAppendLabeledDateTime(box, labelProperty, date, isAllDay ){ var jsDate = new Date(date.getTime()); var formattedDateTime = gCalendarWindow.dateFormater.formatDateTime( jsDate, true, isAllDay ); boxAppendLabeledText(box, labelProperty, formattedDateTime);} |
function boxAppendLabeledDateTimeInterval(box, labelProperty, start, end, isAllDay, relativeToDate) | function boxAppendLabeledDateTimeInterval(box, labelProperty, start, end) | function boxAppendLabeledDateTimeInterval(box, labelProperty, start, end, isAllDay, relativeToDate){ var formattedInterval = gCalendarWindow.dateFormater.formatInterval( start, end, isAllDay, relativeToDate); boxAppendLabeledText(box, labelProperty, formattedInterval);} |
var formattedInterval = gCalendarWindow.dateFormater.formatInterval( start, end, isAllDay, relativeToDate); boxAppendLabeledText(box, labelProperty, formattedInterval); | var dateFormatter = Components.classes["@mozilla.org/calendar/datetime-formatter;1"] .getService(Components.interfaces.calIDateTimeFormatter); var startString = new Object(); var endString = new Object(); start = jsDateToDateTime(start).getInTimezone(calendarDefaultTimezone()); end = jsDateToDateTime(end).getInTimezone... | function boxAppendLabeledDateTimeInterval(box, labelProperty, start, end, isAllDay, relativeToDate){ var formattedInterval = gCalendarWindow.dateFormater.formatInterval( start, end, isAllDay, relativeToDate); boxAppendLabeledText(box, labelProperty, formattedInterval);} |
return; | return true; | function bpr_addscript (scriptRec){ for (var i = 0; i < this.scriptRecords.length; ++i) if (this.scriptRecords[i] == scriptRec) return; if (this._enabled) { var pc = scriptRec.script.lineToPc(this.line, PCMAP_SOURCETEXT); scriptRec.script.setBreakpoint(pc); } this.func... |
if (this._enabled) { var pc = scriptRec.script.lineToPc(this.line, PCMAP_SOURCETEXT); scriptRec.script.setBreakpoint(pc); } this.functionName = scriptRec.functionName; ++(scriptRec.bpcount); this.scriptRecords.push(scriptRec); | return false; | function bpr_addscript (scriptRec){ for (var i = 0; i < this.scriptRecords.length; ++i) if (this.scriptRecords[i] == scriptRec) return; if (this._enabled) { var pc = scriptRec.script.lineToPc(this.line, PCMAP_SOURCETEXT); scriptRec.script.setBreakpoint(pc); } this.func... |
var filterLabel = bundlePreferences.getString("filterWav"); | var wildmat = "*.wav"; var label = bundlePreferences.getFormattedString("filterWav", [wildmat], 1); | browseAlarm: function () { const nsIFilePicker = Components.interfaces.nsIFilePicker; var fp = Components.classes["@mozilla.org/filepicker;1"] .createInstance(nsIFilePicker); var bundlePreferences = document.getElementById("bundlePreferences"); var title = bundlePrefer... |
fp.appendFilter(filterLabel, "*.wav"); | fp.appendFilter(label, wildmat); | browseAlarm: function () { const nsIFilePicker = Components.interfaces.nsIFilePicker; var fp = Components.classes["@mozilla.org/filepicker;1"] .createInstance(nsIFilePicker); var bundlePreferences = document.getElementById("bundlePreferences"); var title = bundlePrefer... |
if ((title == null) || (title == "")) { title = url; } | function BrowserAddBookmark(url,title) { var bmks = Components.classes["component://netscape/browser/bookmarks-service"].getService(); bmks = bmks.QueryInterface(Components.interfaces.nsIBookmarksService); bmks.AddBookmark(url, title); } | |
var svc = Components.classes["component: svc = svc.QueryInterface(Components.interfaces.nsIBookmarksService); svc.AddBookmark(url, title); | var bmks = Components.classes["component: bmks = bmks.QueryInterface(Components.interfaces.nsIBookmarksService); bmks.AddBookmark(url, title); | function BrowserAddBookmark(url,title) { var svc = Components.classes["component://netscape/browser/bookmarks-service"].getService(); svc = svc.QueryInterface(Components.interfaces.nsIBookmarksService); svc.AddBookmark(url, title); } |
getWebNavigation().goBack(); | try { getWebNavigation().goBack(); } catch(ex) { } | function BrowserBack(){ getWebNavigation().goBack(); UpdateBackForwardButtons();} |
refreshBookmarks(); | function BrowserBookmarkThis() { var currentURI=getBrowser().selectedBrowser.webNavigation.currentURI.spec; var newLi=gBookmarksDoc.createElement("li"); var bmContent=gBookmarksDoc.createTextNode(currentURI); newLi.appendChild(bmContent); gBookmarksDoc.getElementsByTagName("bm")[0].appendChild(newLi); ... | |
if (browser && browser.localName == 'tabbrowser' && browser.mTabContainer.childNodes.length > 1) { | if (browser.mTabContainer.childNodes.length > 1) { | function BrowserCloseTabOrWindow(){ var browser = getBrowser(); if (browser && browser.localName == 'tabbrowser' && browser.mTabContainer.childNodes.length > 1) { // Just close up a tab. browser.removeCurrentTab(); return; } BrowserCloseWindow();} |
#ifdef XP_MACOSX if (window.location.href != getBrowserURL()) { closeWindow(true); return; } #endif | function BrowserCloseTabOrWindow(){ if (gBrowser.localName == 'tabbrowser' && gBrowser.tabContainer.childNodes.length > 1) { // Just close up a tab. gBrowser.removeCurrentTab(); return; } BrowserCloseWindow();} | |
if (gBrowser.localName == "tabbrowser" && gBrowser.tabContainer.childNodes.length > 1) { | if (gBrowser.tabContainer.childNodes.length > 1) { | function BrowserCloseTabOrWindow(){#ifdef XP_MACOSX // If we're not a browser window, just close the window if (window.location.href != getBrowserURL()) { closeWindow(true); return; }#endif // XXXzeniko why do we check for gBrowser's localName (it's rather undefined // than actually a different ele... |
if (gBrowser.localName == "tabbrowser" && window.toolbar.visible && | if (window.toolbar.visible && | function BrowserCloseTabOrWindow(){#ifdef XP_MACOSX // If we're not a browser window, just close the window if (window.location.href != getBrowserURL()) { closeWindow(true); return; }#endif // XXXzeniko why do we check for gBrowser's localName (it's rather undefined // than actually a different ele... |
open("chrome: | open("chrome: "chrome,extrachrome,menubar,resizable,scrollbars,status,toolbar"); | function BrowserEditBookmarks(){ // Use a single sidebar bookmarks dialog var windowManager = Components.classes["@mozilla.org/rdf/datasource;1?name=window-mediator"] .getService(Components.interfaces.nsIWindowMediator); var bookmarksWindow = windowManager.getMostRecentWindow("bookmark... |
var bookmarksWindow = windowManager.GetMostRecentWindow('bookmarks:manager'); | var bookmarksWindow = windowManager.getMostRecentWindow('bookmarks:manager'); | function BrowserEditBookmarks(){ // Use a single sidebar bookmarks dialog var cwindowManager = Components.classes['component://netscape/rdf/datasource?name=window-mediator'].getService(); var iwindowManager = Components.interfaces.nsIWindowMediator; var windowManager = cwindowManager.QueryInterface(iwindowManager... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.