mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-22 05:06:09 +03:00
Some issues solved
This commit is contained in:
parent
d5b62aabcd
commit
70bdc8839e
@ -8,10 +8,6 @@
|
|||||||
"off",
|
"off",
|
||||||
4
|
4
|
||||||
],
|
],
|
||||||
//"linebreak-style": [
|
|
||||||
// "error",
|
|
||||||
// "unix"
|
|
||||||
//],
|
|
||||||
"quotes": [
|
"quotes": [
|
||||||
"off",
|
"off",
|
||||||
"double"
|
"double"
|
||||||
|
@ -870,12 +870,12 @@
|
|||||||
* @memberof OpenSeadragon.MouseTracker
|
* @memberof OpenSeadragon.MouseTracker
|
||||||
*/
|
*/
|
||||||
$.MouseTracker.resetAllMouseTrackers = function(){
|
$.MouseTracker.resetAllMouseTrackers = function(){
|
||||||
MOUSETRACKERS.forEach(function(mt){
|
for(var i = 0; i < MOUSETRACKERS.length; i++){
|
||||||
if (mt.isTracking()){
|
if (MOUSETRACKERS[i].isTracking()){
|
||||||
mt.setTracking(false);
|
MOUSETRACKERS[i].setTracking(false);
|
||||||
mt.setTracking(true);
|
MOUSETRACKERS[i].setTracking(true);
|
||||||
}
|
}
|
||||||
});
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -2530,7 +2530,6 @@ function onCanvasDblClick( event ) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// Modified to improve constrained panning
|
|
||||||
function onCanvasDrag( event ) {
|
function onCanvasDrag( event ) {
|
||||||
var gestureSettings;
|
var gestureSettings;
|
||||||
|
|
||||||
@ -2546,14 +2545,14 @@ function onCanvasDrag( event ) {
|
|||||||
if( this.constrainDuringPan ){
|
if( this.constrainDuringPan ){
|
||||||
var delta = this.viewport.deltaPointsFromPixels( event.delta.negate() );
|
var delta = this.viewport.deltaPointsFromPixels( event.delta.negate() );
|
||||||
|
|
||||||
this["viewport"].centerSpringX.target.value += delta.x;
|
this.viewport.centerSpringX.target.value += delta.x;
|
||||||
this["viewport"].centerSpringY.target.value += delta.y;
|
this.viewport.centerSpringY.target.value += delta.y;
|
||||||
|
|
||||||
var bounds = this.viewport.getBounds();
|
var bounds = this.viewport.getBounds();
|
||||||
var constrainedBounds = this.viewport.getConstrainedBounds();
|
var constrainedBounds = this.viewport.getConstrainedBounds();
|
||||||
|
|
||||||
this["viewport"].centerSpringX.target.value -= delta.x;
|
this.viewport.centerSpringX.target.value -= delta.x;
|
||||||
this["viewport"].centerSpringY.target.value -= delta.y;
|
this.viewport.centerSpringY.target.value -= delta.y;
|
||||||
|
|
||||||
if (bounds.x != constrainedBounds.x) {
|
if (bounds.x != constrainedBounds.x) {
|
||||||
event.delta.x = 0;
|
event.delta.x = 0;
|
||||||
|
@ -734,7 +734,7 @@ $.Viewport.prototype = {
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns bounds taking constrains into account
|
* Returns bounds taking constraints into account
|
||||||
* Added to improve constrained panning
|
* Added to improve constrained panning
|
||||||
* @param {Boolean} immediately
|
* @param {Boolean} immediately
|
||||||
* @return {OpenSeadragon.Viewport} Chainable.
|
* @return {OpenSeadragon.Viewport} Chainable.
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
|
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title>CartoWall Climbing Topo</title>
|
<title>Iframe example embed</title>
|
||||||
|
|
||||||
<script type="text/javascript" src='../../build/openseadragon/openseadragon.js'></script>
|
<script type="text/javascript" src='../../build/openseadragon/openseadragon.js'></script>
|
||||||
|
|
@ -1,8 +1,7 @@
|
|||||||
|
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title>CartoWall Climbing Topo</title>
|
<title>Iframe example</title>
|
||||||
|
|
||||||
<script type="text/javascript" src='../../build/openseadragon/openseadragon.js'></script>
|
<script type="text/javascript" src='../../build/openseadragon/openseadragon.js'></script>
|
||||||
|
|
||||||
@ -14,6 +13,6 @@
|
|||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<iframe src="embed.html" frameborder="0" width="560" height="315" allowfullscreen></iframe>
|
<iframe src="iframe-embed.html" frameborder="0" width="560" height="315" allowfullscreen></iframe>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
Loading…
Reference in New Issue
Block a user