mirror of
https://github.com/openseadragon/openseadragon.git
synced 2025-02-01 07:31:41 +03:00
touch-action fixup
This commit is contained in:
parent
3521bac90e
commit
bf19e73f5e
@ -137,10 +137,10 @@ $.Button = function( options ) {
|
||||
this.tooltip;
|
||||
|
||||
this.element.style.position = "relative";
|
||||
if ( this.element.style[ "touch-action" ] !== undefined ) {
|
||||
this.element.style[ "touch-action" ] = "none";
|
||||
} else if ( this.element.style[ "-ms-touch-action" ] !== undefined ) {
|
||||
this.element.style[ "-ms-touch-action" ] = "none";
|
||||
if ( typeof this.element.style.touchAction !== 'undefined' ) {
|
||||
this.element.style.touchAction = 'none';
|
||||
} else if ( typeof this.element.style.msTouchAction !== 'undefined' ) {
|
||||
this.element.style.msTouchAction = 'none';
|
||||
}
|
||||
|
||||
this.imgGroup.style.position =
|
||||
|
@ -80,10 +80,10 @@ $.ButtonGroup = function( options ) {
|
||||
}
|
||||
}
|
||||
|
||||
if ( this.element.style[ "touch-action" ] !== undefined ) {
|
||||
this.element.style[ "touch-action" ] = "none";
|
||||
} else if ( this.element.style[ "-ms-touch-action" ] !== undefined ) {
|
||||
this.element.style[ "-ms-touch-action" ] = "none";
|
||||
if ( typeof this.element.style.touchAction !== 'undefined' ) {
|
||||
this.element.style.touchAction = 'none';
|
||||
} else if ( typeof this.element.style.msTouchAction !== 'undefined' ) {
|
||||
this.element.style.msTouchAction = 'none';
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -112,10 +112,10 @@ $.Navigator = function( options ){
|
||||
|
||||
options.minPixelRatio = this.minPixelRatio = viewer.minPixelRatio;
|
||||
|
||||
if ( this.element.style[ "touch-action" ] !== undefined ) {
|
||||
this.element.style[ "touch-action" ] = "none";
|
||||
} else if ( this.element.style[ "-ms-touch-action" ] !== undefined ) {
|
||||
this.element.style[ "-ms-touch-action" ] = "none";
|
||||
if ( typeof this.element.style.touchAction !== 'undefined' ) {
|
||||
this.element.style.touchAction = 'none';
|
||||
} else if ( typeof this.element.style.msTouchAction !== 'undefined' ) {
|
||||
this.element.style.msTouchAction = 'none';
|
||||
}
|
||||
|
||||
this.borderWidth = 2;
|
||||
|
@ -114,10 +114,10 @@ $.ReferenceStrip = function ( options ) {
|
||||
style.background = '#000';
|
||||
style.position = 'relative';
|
||||
|
||||
if ( this.element.style[ "touch-action" ] !== undefined ) {
|
||||
this.element.style[ "touch-action" ] = "none";
|
||||
} else if ( this.element.style[ "-ms-touch-action" ] !== undefined ) {
|
||||
this.element.style[ "-ms-touch-action" ] = "none";
|
||||
if ( typeof this.element.style.touchAction !== 'undefined' ) {
|
||||
this.element.style.touchAction = 'none';
|
||||
} else if ( typeof this.element.style.msTouchAction !== 'undefined' ) {
|
||||
this.element.style.msTouchAction = 'none';
|
||||
}
|
||||
|
||||
$.setElementOpacity( this.element, 0.8 );
|
||||
@ -195,10 +195,10 @@ $.ReferenceStrip = function ( options ) {
|
||||
element.style.cssFloat = 'left'; //Firefox
|
||||
element.style.styleFloat = 'left'; //IE
|
||||
element.style.padding = '2px';
|
||||
if ( element.style[ "touch-action" ] !== undefined ) {
|
||||
element.style[ "touch-action" ] = "none";
|
||||
} else if ( element.style[ "-ms-touch-action" ] !== undefined ) {
|
||||
element.style[ "-ms-touch-action" ] = "none";
|
||||
if ( typeof element.style.touchAction !== 'undefined' ) {
|
||||
element.style.touchAction = 'none';
|
||||
} else if ( typeof element.style.msTouchAction !== 'undefined' ) {
|
||||
element.style.msTouchAction = 'none';
|
||||
}
|
||||
|
||||
element.innerTracker = new $.MouseTracker( {
|
||||
|
@ -276,10 +276,10 @@ $.Viewer = function( options ) {
|
||||
style.top = "0px";
|
||||
style.left = "0px";
|
||||
// Disable browser default touch handling
|
||||
if ( style[ "touch-action" ] !== undefined ) {
|
||||
style[ "touch-action" ] = "none";
|
||||
} else if ( style["-ms-touch-action"] !== undefined ) {
|
||||
style[ "-ms-touch-action" ] = "none";
|
||||
if ( typeof style.touchAction !== 'undefined' ) {
|
||||
style.touchAction = 'none';
|
||||
} else if ( typeof style.msTouchAction !== 'undefined' ) {
|
||||
style.msTouchAction = 'none';
|
||||
}
|
||||
}(this.canvas.style));
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user