mirror of
https://github.com/ONLYOFFICE/sdkjs.git
synced 2026-04-07 14:09:12 +08:00
Fix bug with focus in mobile version
This commit is contained in:
@ -1642,6 +1642,8 @@
|
||||
touchManager.stopTouchingInProcess();
|
||||
return res;
|
||||
}
|
||||
if (touchManager)
|
||||
touchManager.checkMouseFocus(e);
|
||||
|
||||
var t = this;
|
||||
asc["editor"].checkInterfaceElementBlur();
|
||||
|
||||
@ -764,6 +764,16 @@
|
||||
return true;
|
||||
};
|
||||
|
||||
CMobileTouchManagerBase.prototype.checkMouseFocus = function(e)
|
||||
{
|
||||
// mobile version does not get focus with mouse events
|
||||
if (this.Api.isMobileVersion && e && "mouse" === e.pointerType)
|
||||
{
|
||||
if (AscCommon.g_inputContext)
|
||||
AscCommon.g_inputContext.setInterfaceEnableKeyEvents(true);
|
||||
}
|
||||
};
|
||||
|
||||
CMobileTouchManagerBase.prototype.checkTouchEvent = function(e)
|
||||
{
|
||||
if (!e)
|
||||
|
||||
@ -1990,6 +1990,9 @@
|
||||
return res;
|
||||
}
|
||||
|
||||
if (oThis.touchManager)
|
||||
oThis.touchManager.checkMouseFocus(e);
|
||||
|
||||
oThis.isFocusOnThumbnails = false;
|
||||
AscCommon.stopEvent(e);
|
||||
|
||||
|
||||
@ -3295,6 +3295,9 @@ function CEditorPage(api)
|
||||
return res;
|
||||
}
|
||||
|
||||
if (oThis.MobileTouchManager)
|
||||
oThis.MobileTouchManager.checkMouseFocus(e);
|
||||
|
||||
oThis.m_oApi.checkInterfaceElementBlur();
|
||||
oThis.m_oApi.checkLastWork();
|
||||
|
||||
|
||||
@ -1729,6 +1729,9 @@ function CEditorPage(api)
|
||||
return res;
|
||||
}
|
||||
|
||||
if (oThis.MobileTouchManager)
|
||||
oThis.MobileTouchManager.checkMouseFocus(e);
|
||||
|
||||
oThis.m_oApi.checkInterfaceElementBlur();
|
||||
oThis.m_oApi.checkLastWork();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user