Установил то,о чем писал выше,2003-05-25 Windows build with New Qute,думал посижу на стабильной версии.Оказалось баг с автоскроллом присутствует и здесь,т.е его занесли сюда из последних версий.Бред какой-то...
Добавлено rev3nant Цитата: А чего там в browser.xml править надо?
Вспомнилось,поскольку middle-click-scroll bug не исправляется.
Убираем встроенный Autoscroll. Из browser.xml удаляем следующее:
Код: ]]>
</body>
</method>
<field name="_AUTOSCROLL_SPEED">3</field>
<field name="_AUTOSCROLL_SNAP">10</field>
<field name="_clientFrameDoc">null</field>
<field name="_clientFrameBody">null</field>
<field name="_isScrolling">false</field>
<field name="_autoScrollMarkerImage">null</field>
<field name="_snapOn">false</field>
<field name="_scrollCount">0</field>
<field name="_startX">null</field>
<field name="_startY">null</field>
<field name="_clientX">null</field>
<field name="_clientY">null</field>
<field name="_f">false</field>
<method name="stopScroll">
<body>
<![CDATA[
this._isScrolling = false;
if (this._autoScrollMarkerImage) {
this._autoScrollMarkerImage.style.display = 'none'; // seems to avoid blocking when autoscroll is initited during pageload
this._autoScrollMarkerImage.parentNode.removeChild(this._autoScrollMarkerImage);
}
this._autoScrollMarkerImage = null;
]]>
</body>
</method>
<method name="autoScrollLoop">
<body>
<![CDATA[
if (this._isScrolling) {
var x = (this._clientX - this._startX) / this._AUTOSCROLL_SPEED;
var y = (this._clientY - this._startY) / this._AUTOSCROLL_SPEED;
if(Math.abs(x) > 0 && Math.abs(y) > 0)
{
if (this._scrollCount++ % 2)
y = 0;
else
x = 0;
}
this._clientFrameDoc.defaultView.scrollBy(x, y);
setTimeout(function foo(a) { a.autoScrollLoop() }, 5, this);
}
]]>
</body>
</method>
<method name="isLink">
<parameter name="node"/>
<body>
<![CDATA[
if (!node) return false;
if (node.nodeName == "A" || node.nodeName == "INPUT" || node.nodeName == "TEXTAREA" ||
node.nodeName == "AREA") {
return true;
}
return this.isLink(node.parentNode);
]]>
</body>
</method>
<method name="showAutoscrollMarker">
<parameter name="evt"/>
<body>
<![CDATA[
var scrollCursor = new Array("move", "n-resize", "e-resize");
var docBox = this._clientFrameDoc.getBoxObjectFor(this._clientFrameDoc.documentElement);
var left = evt.screenX - docBox.screenX;
var top = evt.screenY - docBox.screenY;
var documentWidth = docBox.width;
var documentHeight = docBox.height;
var windowWidth = window.innerWidth;
var windowHeight = window.innerHeight;
var scrollType = 0;
if (windowHeight < documentHeight && windowWidth >= documentWidth)
scrollType = 1;
else if (windowHeight >= documentHeight && windowWidth < documentWidth)
scrollType = 2;
var imageWidth = 28;
var imageHeight = 28;
// marker
var el = this._clientFrameDoc.createElementNS("http://www.w3.org/1999/xhtml", "img");
var scrollImages = new Array("chrome://global/content/widgets/autoscroll_all.png",
"chrome://global/content/widgets/autoscroll_v.png",
"chrome://global/content/widgets/autoscroll_h.png");
el.src = scrollImages[scrollType];
el.style.position = "fixed";
el.style.left = left - imageWidth / 2 + "px";
el.style.top = top - imageHeight / 2 + "px";
el.style.width = imageWidth + "px";
el.style.height = imageHeight + "px";
el.style.cursor = scrollCursor[scrollType];
this._clientFrameBody.appendChild(el);
this._autoScrollMarkerImage = el;
----------------------------------------------------------------
]]>
</handler>
<handler event="mouseup">
<![CDATA[
if (!this._snapOn)
this.stopScroll();
else {
if (this._f) {
this._f = false;
return;
}
if (event.button == 1)
this.showAutoscrollMarker(event);
}
]]>
</handler>
<handler event="mousedown">
<![CDATA[
if (!this._isScrolling) {
if (event.button == 1) {
this._startX = event.clientX;
this._startY = event.clientY;
this._clientFrameDoc = event.originalTarget.ownerDocument;
this._clientFrameBody = (this._clientFrameDoc.getElementsByTagName('body')[0]) ? this._clientFrameDoc.getElementsByTagName('body')[0] : this._clientFrameDoc.getElementsByTagName('*')[0];
this._isScrolling = true;
if (!this.isLink(event.originalTarget))
this._snapOn = true;
window.setTimeout(function foo(a) { a.autoScrollLoop() }, 5, this);
}
}
else {
if (event.originalTarget == this._autoScrollMarkerImage)
this._f = true;
stopScroll();
}
]]>
</handler>
<handler event="mousemove">
<![CDATA[
this._clientX = event.clientX;
this._clientY = event.clientY;
if (this._isScrolling) {
var x = this._clientX - this._startX;
var y = this._clientY - this._startY;
if ((x > this._AUTOSCROLL_SNAP || x < -this._AUTOSCROLL_SNAP) || (y > this._AUTOSCROLL_SNAP || y < -this._AUTOSCROLL_SNAP)) {
this._snapOn = false;
if (!this._autoScrollMarkerImage)
this.showAutoscrollMarker(event);
}
}