Update PCT Trace
This commit is contained in:
64543
geo/pct.gpx
64543
geo/pct.gpx
File diff suppressed because it is too large
Load Diff
@@ -291,7 +291,7 @@
|
||||
});
|
||||
|
||||
//Manage Repositioning Event
|
||||
this.$nav.on('mousedown', (e)=>{
|
||||
this.$nav.on('mousedown', (e) => {
|
||||
if(this.$image.css('--scale') > 1) {
|
||||
//The following block gets the X/Y offset (the difference between where it starts and where it was clicked)
|
||||
this.gMouseDownOffsetX = e.clientX - parseFloat(this.$image.css('--translate-x') || 0);
|
||||
@@ -304,20 +304,17 @@
|
||||
}
|
||||
});
|
||||
|
||||
$window.on('mouseup', ()=>{
|
||||
$window.on('mouseup', () => {
|
||||
$window.off('mousemove', divMove);
|
||||
this.$container.removeClass('moving');
|
||||
});
|
||||
|
||||
function divMove(e){
|
||||
//var oImage = self.album[self.currentImageIndex];
|
||||
let iZoom = self.$image.css('--scale');
|
||||
|
||||
let fTransX = e.clientX - self.gMouseDownOffsetX;
|
||||
let fTransY = e.clientY - self.gMouseDownOffsetY;
|
||||
|
||||
var fTransMaxX = (iZoom - 1) * self.$image.width() / 2;
|
||||
var fTransMaxY = (iZoom - 1) * self.$image.height() / 2;
|
||||
let fTransMaxX = (iZoom - 1) * self.$image.width() / 2;
|
||||
let fTransMaxY = (iZoom - 1) * self.$image.height() / 2;
|
||||
|
||||
fTransX = Math.max(Math.min(fTransX, fTransMaxX), fTransMaxX * -1);
|
||||
fTransY = Math.max(Math.min(fTransY, fTransMaxY), fTransMaxY * -1);
|
||||
|
||||
Reference in New Issue
Block a user