diff options
| author | andrewdkim <adkim414@gmail.com> | 2019-10-02 15:59:56 -0400 |
|---|---|---|
| committer | andrewdkim <adkim414@gmail.com> | 2019-10-02 15:59:56 -0400 |
| commit | 00416cdb70aa8dd9698972ab0df8ca0a6c8575f9 (patch) | |
| tree | fb446dbdf8ff37d58aaa92019ae3edf72409900b /src/client/views/nodes/PresBox.tsx | |
| parent | 2f09822358dba784ec26d5707423b4025096ee45 (diff) | |
Merge branch 'master' of https://github.com/browngraphicslab/Dash-Web into animationtimeline_two
Diffstat (limited to 'src/client/views/nodes/PresBox.tsx')
| -rw-r--r-- | src/client/views/nodes/PresBox.tsx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/client/views/nodes/PresBox.tsx b/src/client/views/nodes/PresBox.tsx index e376fbddb..5afd85430 100644 --- a/src/client/views/nodes/PresBox.tsx +++ b/src/client/views/nodes/PresBox.tsx @@ -161,10 +161,8 @@ export class PresBox extends React.Component<FieldViewProps> { //FieldViewProps? if (zoomOut || this.presElementsMappings.get(docAtCurrent)!.showButton) { let prevScale = NumCast(this.childrenDocs[prevSelected].viewScale, null); let curScale = DocumentManager.Instance.getScaleOfDocView(this.childrenDocs[current]); - if (prevScale !== undefined) { - if (prevScale !== curScale) { - DocumentManager.Instance.zoomIntoScale(docAtCurrent, prevScale); - } + if (prevScale !== undefined && prevScale !== curScale) { + DocumentManager.Instance.zoomIntoScale(docAtCurrent, prevScale); } } } |
