diff options
| author | Bob Zeleznik <zzzman@gmail.com> | 2020-06-04 14:07:43 -0400 |
|---|---|---|
| committer | Bob Zeleznik <zzzman@gmail.com> | 2020-06-04 14:07:43 -0400 |
| commit | e843c87375e85466dc80b11e4f3d10251a0ebe94 (patch) | |
| tree | abfe615777e18dd3adf87da53386468a1118e131 /src/client/views/collections/CollectionStackingView.tsx | |
| parent | e872414f24edddb31a82738bff10e5b9519d92be (diff) | |
prevented colectionstackview scrolling when nested collctions are scrolled
Diffstat (limited to 'src/client/views/collections/CollectionStackingView.tsx')
| -rw-r--r-- | src/client/views/collections/CollectionStackingView.tsx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/client/views/collections/CollectionStackingView.tsx b/src/client/views/collections/CollectionStackingView.tsx index 7fd19a23c..bd48d1727 100644 --- a/src/client/views/collections/CollectionStackingView.tsx +++ b/src/client/views/collections/CollectionStackingView.tsx @@ -474,7 +474,10 @@ export class CollectionStackingView extends CollectionSubView(StackingDocument) width: `${1 / this.scaling * 100}%`, transformOrigin: "top left", }} - onScroll={action((e: React.UIEvent<HTMLDivElement>) => this._scroll = e.currentTarget.scrollTop)} + onScroll={action(e => { + if (!this.props.isSelected()) e.currentTarget.scrollTop = this._scroll; + else this._scroll = e.currentTarget.scrollTop; + })} onDrop={this.onExternalDrop.bind(this)} onContextMenu={this.onContextMenu} onWheel={e => this.props.active() && e.stopPropagation()} > |
