%findBarDTD; ]> null null null null null Components.classes['@mozilla.org/preferences-service;1'] .getService(Components.interfaces.nsIPrefService) .getBranch(null); Components.classes['@mozilla.org/atom-service;1'] .getService(Components.interfaces.nsIAtomService); null // see bug 63370 for details this._mStrBundle = Components.classes["@mozilla.org/intl/stringbundle;1"] .getService(Components.interfaces.nsIStringBundleService) .createBundle("chrome://global/locale/browser.properties"); } return this._mStrBundle; ]]> null null 1 null false false null false 0) this.sessionHistory.PurgeHistory(purge); ]]> 3 10 null null null null null null null false 8) { // need high color for transparency // Exclude second-rate platforms this._autoScrollPopup.setAttribute("transparent", !/BeOS|OS\/2|Photon/.test(navigator.appVersion)); // Enable translucency on Windows and Mac this._autoScrollPopup.setAttribute("translucent", /Win|Mac/.test(navigator.platform)); } // go upward in the DOM and find any parent element that has a overflow // area and can therefore be scrolled for (this._scrollable = event.originalTarget; this._scrollable; this._scrollable = this._scrollable.parentNode) { // do not use overflow based autoscroll for Elements // or non-html elements such as svg or Document nodes if (!(this._scrollable instanceof HTMLElement) || (this._scrollable instanceof HTMLHtmlElement)) { continue; } var overflowx = this._scrollable.ownerDocument.defaultView .getComputedStyle(this._scrollable, '') .getPropertyValue('overflow-x'); var overflowy = this._scrollable.ownerDocument.defaultView .getComputedStyle(this._scrollable, '') .getPropertyValue('overflow-y'); var scrollVert = this._scrollable.scrollHeight > this._scrollable.offsetHeight && overflowy != 'hidden' && overflowy != 'visible'; // do not allow horizontal scrolling for select elements, it leads // to visual artifacts and is not the expected behavior anyway if (!(this._scrollable instanceof HTMLSelectElement) && this._scrollable.scrollWidth > this._scrollable.offsetWidth && overflowx != 'hidden' && overflowx != 'visible') { this._autoScrollPopup.setAttribute("scrolldir", scrollVert ? "NSEW" : "EW"); break; } else if (scrollVert) { this._autoScrollPopup.setAttribute("scrolldir", "NS"); break; } } if (!this._scrollable) { this._scrollable = event.originalTarget.ownerDocument.defaultView; if (this._scrollable.scrollMaxX > 0) { this._autoScrollPopup.setAttribute("scrolldir", this._scrollable.scrollMaxY > 0 ? "NSEW" : "EW"); } else if (this._scrollable.scrollMaxY > 0) { this._autoScrollPopup.setAttribute("scrolldir", "NS"); } else { this._scrollable = null; // abort scrolling return; } } document.popupNode = null; this._autoScrollPopup.showPopup(document.documentElement, event.screenX, event.screenY, "popup", null, null); this._ignoreMouseEvents = true; this._startX = event.screenX; this._startY = event.screenY; this._screenX = event.screenX; this._screenY = event.screenY; window.addEventListener("mousemove", this, true); window.addEventListener("mousedown", this, true); window.addEventListener("mouseup", this, true); window.addEventListener("contextmenu", this, true); window.addEventListener("keydown", this, true); window.addEventListener("keypress", this, true); window.addEventListener("keyup", this, true); this._scrollErrorX = 0; this._scrollErrorY = 0; this._autoScrollTimer = setInterval(function(self) { self.autoScrollLoop(); }, 20, this); ]]> 0) return Math.floor(num); return Math.ceil(num); ]]> 1) return val * Math.sqrt(val) - 1; if (val < -1) return val * Math.sqrt(-val) + 1; return 0; ]]> this._AUTOSCROLL_SNAP || x < -this._AUTOSCROLL_SNAP) || (y > this._AUTOSCROLL_SNAP || y < -this._AUTOSCROLL_SNAP)) this._ignoreMouseEvents = false; break; } case "mouseup": case "mousedown": case "contextmenu": { if (!this._ignoreMouseEvents) this._autoScrollPopup.hidePopup(); this._ignoreMouseEvents = false; break; } case "popuphidden": { this._autoScrollPopup.removeEventListener("popuphidden", this, true); this.stopScroll(); break; } case "keypress": { if (aEvent.keyCode == aEvent.DOM_VK_ESCAPE) { // the escape key will be processed by // nsXULPopupManager::KeyPress and the panel will be closed. // So, nothing to do here. break; } // don't break here. we need to eat keypress events. } case "keydown": case "keyup": { // All keyevents should be eaten here during autoscrolling. aEvent.stopPropagation(); aEvent.preventDefault(); break; } } } ]]> if one is in a and one is not"; if (!ourTabBrowser) fieldsToSwap.push("_fastFind"); var ourFieldValues = {}; var otherFieldValues = {}; for each (var field in fieldsToSwap) { ourFieldValues[field] = this[field]; otherFieldValues[field] = aOtherBrowser[field]; } this.QueryInterface(Components.interfaces.nsIFrameLoaderOwner) .swapFrameLoaders(aOtherBrowser); for each (var field in fieldsToSwap) { this[field] = otherFieldValues[field]; aOtherBrowser[field] = ourFieldValues[field]; } ]]>