Commit 32e1c881 authored by Dmitry.Shahtanov's avatar Dmitry.Shahtanov Committed by Alexander.Trofimov

вернул Revision: 51046,

fix: Bug 20829 - При перемещении курсора на меню, если был зажат курсор на скролле списка слайдов, выбор слайда происходит со 2 клика

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@51081 954022d7-b5bf-4e40-9824-e11837661b57
parent e7924d10
......@@ -271,6 +271,7 @@ function ScrollObject( elemID, settings, dbg ) {
this.moveble = false;
this.lock = false;
this.scrollTimeout = null;
this.StartMousePosition = {x:0, y:0};
this.EndMousePosition = {x:0, y:0};
......@@ -1122,6 +1123,8 @@ ScrollObject.prototype = {
evt_mouseup:function ( e ) {
var evt = e || windows.event;
var mousePos = this.that.getMousePosition( evt );
this.that.scrollTimeout && clearTimeout( this.that.scrollTimeout );
this.that.scrollTimeout = null;
if ( !this.that.scrollerMouseDown ) {
if ( this.that.settings.showArrows && this.that._MouseHoverOnArrowDown( mousePos ) ) {
this.that.handleEvents( "onmouseup", evt );
......@@ -1178,7 +1181,6 @@ ScrollObject.prototype = {
direction = mousePos.y - this.that.scroller.y - this.that.scroller.h / 2,
step = this.that.paneHeight * this.that.settings.scrollPagePercent,
verticalDragPosition = this.that.scroller.y,
scrollTimeout,
isFirst = true,
doScroll = function () {
_tmp.that.lock = true;
......@@ -1204,12 +1206,12 @@ ScrollObject.prototype = {
return;
}
}
scrollTimeout = setTimeout( doScroll, isFirst ? _tmp.that.settings.initialDelay : _tmp.that.settings.trackClickRepeatFreq );
_tmp.that.scrollTimeout = setTimeout( doScroll, isFirst ? _tmp.that.settings.initialDelay : _tmp.that.settings.trackClickRepeatFreq );
isFirst = false;
},
cancelClick = function () {
scrollTimeout && clearTimeout( scrollTimeout );
scrollTimeout = null;
_tmp.that.scrollTimeout && clearTimeout( _tmp.that.scrollTimeout );
_tmp.that.scrollTimeout = null;
_tmp.that.unbind( "mouseup.main", cancelClick );
_tmp.that.lock = false;
};
......@@ -1221,7 +1223,6 @@ ScrollObject.prototype = {
direction = mousePos.x - this.that.scroller.x - this.that.scroller.w / 2,
step = this.that.paneWidth * this.that.settings.scrollPagePercent,
horizontalDragPosition = this.that.scroller.x,
scrollTimeout,
isFirst = true,
doScroll = function () {
_tmp.that.lock = true;
......@@ -1247,12 +1248,12 @@ ScrollObject.prototype = {
return;
}
}
scrollTimeout = setTimeout( doScroll, isFirst ? _tmp.that.settings.initialDelay : _tmp.that.settings.trackClickRepeatFreq );
_tmp.that.scrollTimeout = setTimeout( doScroll, isFirst ? _tmp.that.settings.initialDelay : _tmp.that.settings.trackClickRepeatFreq );
isFirst = false;
},
cancelClick = function () {
scrollTimeout && clearTimeout( scrollTimeout );
scrollTimeout = null;
_tmp.that.scrollTimeout && clearTimeout( _tmp.that.scrollTimeout );
_tmp.that.scrollTimeout = null;
_tmp.that.unbind( "mouseup.main", cancelClick );
_tmp.that.lock = false;
};
......
......@@ -2449,7 +2449,7 @@ cFormulaFunction.Statistical = {
r.getInfo = function () {
return {
name:this.name,
args:"( number-successes , number-trials , success-probability )"
args:"( number-failures , number-successes , success-probability )"
};
}
return r;
......@@ -2924,7 +2924,7 @@ cFormulaFunction.Statistical = {
r.getInfo = function () {
return {
name:this.name,
args:"( argument-list )"
args:"( array , x [ , significance ] )"
};
}
return r;
......
......@@ -979,6 +979,8 @@
/** @param event {jQuery.Event} */
_onWindowMouseUp: function (event) {
this.vsbApi.evt_mouseup(event);
this.hsbApi.evt_mouseup(event);
// Shapes
var coord = this._getCoordinates(event);
if ( this.isGraphicObjectMode ) {
......
......@@ -386,6 +386,10 @@ function Window_OnMouseUp(e)
{
editor.WordControl.m_oDrawingDocument.UnlockCursorType();
editor.WordControl.m_oDrawingDocument.SetCursorType("default");
if( editor.WordControl.m_oScrollVerApi )
editor.WordControl.m_oScrollVerApi.evt_mouseup(e);
if( editor.WordControl.m_oScrollHorApi )
editor.WordControl.m_oScrollHorApi.evt_mouseup(e);
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment