fix some errors/better dragging + evaluate
Signed-off-by: Victor Seiji Hariki <victorseijih@gmail.com>
This commit is contained in:
parent
a47fc3ee25
commit
61da4b9d58
2 changed files with 7 additions and 7 deletions
|
@ -306,6 +306,10 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Configuration -->
|
||||
<script src="js/global.js" type="text/javascript"></script>
|
||||
<script src="js/config.js" type="text/javascript"></script>
|
||||
|
||||
<!-- Base Libs -->
|
||||
<script src="js/lib/util.js" type="text/javascript"></script>
|
||||
<script src="js/lib/events.js" type="text/javascript"></script>
|
||||
|
@ -320,11 +324,7 @@
|
|||
src="js/initalize/layers.populate.js"
|
||||
type="text/javascript"></script>
|
||||
|
||||
<!-- Configuration -->
|
||||
<script src="js/config.js" type="text/javascript"></script>
|
||||
|
||||
<!-- Content -->
|
||||
<script src="js/global.js" type="text/javascript"></script>
|
||||
<script src="js/prompt.js" type="text/javascript"></script>
|
||||
<script src="js/index.js" type="text/javascript"></script>
|
||||
|
||||
|
|
|
@ -220,6 +220,7 @@ window.addEventListener(
|
|||
const key = buttons[evn.button];
|
||||
if (
|
||||
(!target || target === evn.target) &&
|
||||
mouse.coords[name].dragging[key] &&
|
||||
!mouse.coords[name].dragging[key].drag &&
|
||||
key
|
||||
) {
|
||||
|
@ -273,13 +274,12 @@ window.addEventListener(
|
|||
(evn) => {
|
||||
const time = performance.now();
|
||||
|
||||
mouse._contexts.forEach(({target, name, buttons, validate}) => {
|
||||
mouse._contexts.forEach(({target, name, buttons}) => {
|
||||
const key = buttons[evn.button];
|
||||
if (
|
||||
(!target || target === evn.target) &&
|
||||
key &&
|
||||
mouse.coords[name].dragging[key] &&
|
||||
(!validate || validate(evn))
|
||||
mouse.coords[name].dragging[key]
|
||||
) {
|
||||
const start = {
|
||||
x: mouse.coords[name].dragging[key].x,
|
||||
|
|
Loading…
Reference in a new issue