mirror of
https://github.com/hodgef/simple-keyboard.git
synced 2025-02-21 00:23:02 +08:00
Build update
This commit is contained in:
parent
564aa188e4
commit
38d9a635b8
@ -1,6 +1,6 @@
|
||||
/*!
|
||||
*
|
||||
* simple-keyboard v2.19.1
|
||||
* simple-keyboard v2.20.0
|
||||
* https://github.com/hodgef/simple-keyboard
|
||||
*
|
||||
* Copyright (c) Francisco Hodge (https://github.com/hodgef)
|
||||
|
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
||||
/*!
|
||||
*
|
||||
* simple-keyboard v2.19.1 (Non-minified build)
|
||||
* simple-keyboard v2.20.0 (Non-minified build)
|
||||
* https://github.com/hodgef/simple-keyboard
|
||||
*
|
||||
* Copyright (c) Francisco Hodge (https://github.com/hodgef)
|
||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
||||
/*!
|
||||
*
|
||||
* simple-keyboard v2.19.1 (Non-minified build)
|
||||
* simple-keyboard v2.20.0 (Non-minified build)
|
||||
* https://github.com/hodgef/simple-keyboard
|
||||
*
|
||||
* Copyright (c) Francisco Hodge (https://github.com/hodgef)
|
||||
@ -958,8 +958,16 @@
|
||||
value: function handleButtonMouseDown(button, e) {
|
||||
var _this2 = this;
|
||||
/**
|
||||
* Handle event options
|
||||
*/ if (this.options.preventMouseDownDefault) {
|
||||
e.preventDefault();
|
||||
}
|
||||
if (this.options.stopMouseDownPropagation) {
|
||||
e.stopPropagation();
|
||||
/**
|
||||
* @type {boolean} Whether the mouse is being held onKeyPress
|
||||
*/ this.isMouseHold = true;
|
||||
*/ }
|
||||
this.isMouseHold = true;
|
||||
if (this.holdInteractionTimeout) {
|
||||
clearTimeout(this.holdInteractionTimeout);
|
||||
}
|
||||
@ -1581,18 +1589,12 @@
|
||||
* Handle button click event
|
||||
*/ /* istanbul ignore next */ if (_this10.utilities.pointerEventsSupported() && !useTouchEvents && !useMouseEvents) {
|
||||
/**
|
||||
* PointerEvents support
|
||||
* Handle PointerEvents
|
||||
*/ buttonDOM.onpointerdown = function(e) {
|
||||
if (_this10.options.preventMouseDownDefault) {
|
||||
e.preventDefault();
|
||||
}
|
||||
_this10.handleButtonClicked(button);
|
||||
_this10.handleButtonMouseDown(button, e);
|
||||
};
|
||||
buttonDOM.onpointerup = function(e) {
|
||||
if (_this10.options.preventMouseDownDefault) {
|
||||
e.preventDefault();
|
||||
}
|
||||
_this10.handleButtonMouseUp();
|
||||
};
|
||||
buttonDOM.onpointercancel = function(e) {
|
||||
@ -1602,7 +1604,9 @@
|
||||
/**
|
||||
* Fallback for browsers not supporting PointerEvents
|
||||
*/ if (useTouchEvents) {
|
||||
buttonDOM.ontouchstart = function(e) {
|
||||
/**
|
||||
* Handle touch events
|
||||
*/ buttonDOM.ontouchstart = function(e) {
|
||||
_this10.handleButtonClicked(button);
|
||||
_this10.handleButtonMouseDown(button, e);
|
||||
};
|
||||
@ -1613,14 +1617,13 @@
|
||||
return _this10.handleButtonMouseUp();
|
||||
};
|
||||
} else {
|
||||
buttonDOM.onclick = function() {
|
||||
/**
|
||||
* Handle mouse events
|
||||
*/ buttonDOM.onclick = function() {
|
||||
_this10.isMouseHold = false;
|
||||
_this10.handleButtonClicked(button);
|
||||
};
|
||||
buttonDOM.onmousedown = function(e) {
|
||||
if (_this10.options.preventMouseDownDefault) {
|
||||
e.preventDefault();
|
||||
}
|
||||
_this10.handleButtonMouseDown(button, e);
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user