aboutsummaryrefslogtreecommitdiff
path: root/src/fields/Doc.ts
diff options
context:
space:
mode:
authorLionel Han <47760119+IGoByJoe@users.noreply.github.com>2020-06-29 14:42:36 -0700
committerLionel Han <47760119+IGoByJoe@users.noreply.github.com>2020-06-29 14:42:36 -0700
commit2646aa86bc6d676e848028601f9a4fedeefe35be (patch)
tree42d208346a283f788268c9d74de7dcc835bd84a6 /src/fields/Doc.ts
parent992a65ec6f828dda0adcd3cd121896f07f64af87 (diff)
parent73bbc602fb964c82999faccfdde8eeca6fbf08c4 (diff)
pull
Diffstat (limited to 'src/fields/Doc.ts')
-rw-r--r--src/fields/Doc.ts3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/fields/Doc.ts b/src/fields/Doc.ts
index 8c8720179..dd7117594 100644
--- a/src/fields/Doc.ts
+++ b/src/fields/Doc.ts
@@ -973,7 +973,7 @@ export namespace Doc {
export function toggleNativeDimensions(layoutDoc: Doc, contentScale: number, panelWidth: number, panelHeight: number) {
runInAction(() => {
if (layoutDoc._nativeWidth || layoutDoc._nativeHeight) {
- layoutDoc.scale = NumCast(layoutDoc.scale, 1) * contentScale;
+ layoutDoc._viewScale = NumCast(layoutDoc._viewScale, 1) * contentScale;
layoutDoc._nativeWidth = undefined;
layoutDoc._nativeHeight = undefined;
}
@@ -1159,7 +1159,6 @@ Scripting.addGlobal(function activePresentationItem() {
const curPres = Doc.UserDoc().activePresentation as Doc;
return curPres && DocListCast(curPres[Doc.LayoutFieldKey(curPres)])[NumCast(curPres._itemIndex)];
});
-Scripting.addGlobal(function selectDoc(doc: any) { Doc.UserDoc().activeSelection = new List([doc]); });
Scripting.addGlobal(function selectedDocs(container: Doc, excludeCollections: boolean, prevValue: any) {
const docs = DocListCast(Doc.UserDoc().activeSelection).
filter(d => !Doc.AreProtosEqual(d, container) && !d.annotationOn && d.type !== DocumentType.DOCHOLDER && d.type !== DocumentType.KVP &&