deck.gl
deck.gl copied to clipboard
OrthographicView: Panning outside of viewport causes panmove to fire inside of viewport
Description
When there are multiple views each with its own controller, panning outside of a viewport currently would cause panmove inside of the viewport to be fired.
This shouldn't happen.
"_onPanStart" already checks for this problem:
if (!this.isPointInBounds(pos)) {
return false;
}
"_onPanMove" needs checks too.
Repro Steps
<DeckGL
views={[
new OrthographicView({
id: 'v1',
width: '50%',
controller: {
dragRotate: false,
dragPan: true
}
}),
new OrthographicView({
id: 'v2',
width: '50%',
x: '50%',
controller: {
dragRotate: false,
dragPan: true
}
})
})
]}
layers={[layer]}
// initialViewState={initialViewState}
viewState={viewState}
onViewStateChange={ e=>setViewState(e.viewState)}
/>)
Environment (please complete the following information):
- Framework Version: [deck.gl 6.4.5]
- Browser Version: [Chrome 72.0.3626.121 ]
- OS: [Mac OS X 10.14.3]