diff options
author | bobzel <zzzman@gmail.com> | 2020-10-15 15:29:18 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2020-10-15 15:29:18 -0400 |
commit | 9ebb6c94f35c7d53b0bb4e9842784e99d3b28c07 (patch) | |
tree | 5c042f6b0788163764e001188015aecc128c499c /src/client/views/DocumentButtonBar.tsx | |
parent | f1ee3a6baffb22093d81e123d70f6ec9631c2075 (diff) | |
parent | 377d5c987728c2678ab38565328f1f7ad9f3d135 (diff) |
Merge branch 'master' of https://github.com/browngraphicslab/Dash-Web
Diffstat (limited to 'src/client/views/DocumentButtonBar.tsx')
-rw-r--r-- | src/client/views/DocumentButtonBar.tsx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/client/views/DocumentButtonBar.tsx b/src/client/views/DocumentButtonBar.tsx index d8c32a919..9dddb4c44 100644 --- a/src/client/views/DocumentButtonBar.tsx +++ b/src/client/views/DocumentButtonBar.tsx @@ -25,6 +25,7 @@ import { GoogleRef } from "./nodes/formattedText/FormattedTextBox"; import { TemplateMenu } from "./TemplateMenu"; import React = require("react"); import { PresBox } from './nodes/PresBox'; +import { undoBatch } from '../util/UndoManager'; const higflyout = require("@hig/flyout"); export const { anchorPoints } = higflyout; export const Flyout = higflyout.default; @@ -199,7 +200,7 @@ export class DocumentButtonBar extends React.Component<{ views: () => (DocumentV const targetDoc = this.view0?.props.Document; return !targetDoc ? (null) : <Tooltip title={<><div className="dash-tooltip">{"Pin with current view"}</div></>}> <div className="documentButtonBar-linker" - onClick={e => { + onClick={undoBatch(e => { if (targetDoc) { TabDocView.PinDoc(targetDoc, false); const activeDoc = PresBox.Instance.childDocs[PresBox.Instance.childDocs.length - 1]; @@ -211,7 +212,7 @@ export class DocumentButtonBar extends React.Component<{ views: () => (DocumentV activeDoc.presPinViewY = y; activeDoc.presPinViewScale = scale; } - }}> + })}> {presPinWithViewIcon} </div> </Tooltip>; |