We have a viewer with coded on openseadragon. It has zoomin zoomout home and rotate functions. We also add some custom transparent canvas on this viewer for draw some shapes on that picture. They works fine but we cannot drag that pictures and also cannot get div coordinates that picture on these multi canvas.
How can we reach mouse move or click and drag events on this multi canvas.
Thanks all for helping.
Example code here:
<div class="container">
<div class="area">
<div id="viewerImage1"
class="openseadragon">
<script type="text/javascript">
var meta = null;
var viewer = OpenSeadragon({
id: "viewerImage1",
prefixUrl: "/openseadragon/images/",
tileSources: {
type: 'image',
url: '/openseadragon/images/example-images/sample.jpg'
}
});
</script>
</div>
<canvas id="canvasDrawArea01" class="canvas" width="300" height="250" style="cursor: move;"></canvas>
<canvas id="canvasDrawArea02" class="canvas" width="300" height="250" style="cursor: move;"></canvas>
</div>
</div>