diff options
| author | Aubrey-Li <63608597+Aubrey-Li@users.noreply.github.com> | 2021-08-05 19:40:00 -0700 |
|---|---|---|
| committer | Aubrey-Li <63608597+Aubrey-Li@users.noreply.github.com> | 2021-08-05 19:40:00 -0700 |
| commit | 17e50d9e69c7d59c7d4c2be5c75c51b3e02bc698 (patch) | |
| tree | 92fb6ffed0ad68260885712ad71bfa8dfa21c06b /src/client/views/collections/CollectionMenu.tsx | |
| parent | a5a7a94d3c52cdb230ff3d93790850329940abcf (diff) | |
| parent | de45cc09b8fe4e6231f0e568443f3c6e262f97ea (diff) | |
Merge branch 'master' into trails-aubrey
Diffstat (limited to 'src/client/views/collections/CollectionMenu.tsx')
| -rw-r--r-- | src/client/views/collections/CollectionMenu.tsx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/client/views/collections/CollectionMenu.tsx b/src/client/views/collections/CollectionMenu.tsx index f96615ded..a5f54c342 100644 --- a/src/client/views/collections/CollectionMenu.tsx +++ b/src/client/views/collections/CollectionMenu.tsx @@ -666,7 +666,7 @@ export class CollectionFreeFormViewChrome extends React.Component<CollectionMenu } @computed get drawButtons() { - const func = action((i: number, keep: boolean) => { + const func = action((e: React.MouseEvent | React.PointerEvent, i: number, keep: boolean) => { this._keepPrimitiveMode = keep; if (this._selectedPrimitive !== i) { this._selectedPrimitive = i; @@ -684,13 +684,14 @@ export class CollectionFreeFormViewChrome extends React.Component<CollectionMenu GestureOverlay.Instance.InkShape = ""; SetActiveBezierApprox("0"); } + e.stopPropagation(); }); return <div className="btn-draw" key="draw"> {this._draw.map((icon, i) => <Tooltip key={icon} title={<div className="dash-tooltip">{this._title[i]}</div>} placement="bottom"> <button className="antimodeMenu-button" - onPointerDown={() => func(i, false)} - onDoubleClick={() => func(i, true)} + onPointerDown={e => func(e, i, false)} + onDoubleClick={e => func(e, i, true)} style={{ backgroundColor: i === this._selectedPrimitive ? "525252" : "", fontSize: "20" }}> <FontAwesomeIcon icon={this._faName[i] as IconProp} size="sm" /> </button> |
