From e3132b1f9adfe895a0f669993c4fd1f1ec36877e Mon Sep 17 00:00:00 2001 From: Lionel Han <47760119+IGoByJoe@users.noreply.github.com> Date: Mon, 1 Jun 2020 22:35:36 -0700 Subject: kinda functioning ink --- src/mobile/MobileInterface.tsx | 46 +++++++++++++++++++----------------------- 1 file changed, 21 insertions(+), 25 deletions(-) (limited to 'src/mobile') diff --git a/src/mobile/MobileInterface.tsx b/src/mobile/MobileInterface.tsx index 4c2d20208..a09854ea2 100644 --- a/src/mobile/MobileInterface.tsx +++ b/src/mobile/MobileInterface.tsx @@ -81,6 +81,8 @@ export default class MobileInterface extends React.Component { } InkingControl.Instance.switchTool(InkTool.None) MobileInterface.Instance.drawingInk = false; + InkingControl.Instance.updateSelectedColor("rgb(0, 0, 0)"); + InkingControl.Instance.switchWidth("2"); } @action @@ -99,21 +101,10 @@ export default class MobileInterface extends React.Component { MobileInterface.Instance.drawingInk = true; this._ink = true; - DocServer.Mobile.dispatchOverlayTrigger({ - enableOverlay: true, - width: window.innerWidth, - height: window.innerHeight - }); } else { InkingControl.Instance.switchTool(InkTool.None) MobileInterface.Instance.drawingInk = false; this._ink = false; - - DocServer.Mobile.dispatchOverlayTrigger({ - enableOverlay: false, - width: window.innerWidth, - height: window.innerHeight - }); } this.toggleSidebar(); @@ -183,6 +174,7 @@ export default class MobileInterface extends React.Component { if (doc) { this._activeDoc = doc; } + this._ink = false; } returnHome = () => { @@ -282,18 +274,7 @@ export default class MobileInterface extends React.Component { renderDefaultContent = () => { const workspaces = Cast(this.userDoc.myWorkspaces, Doc) as Doc; let buttons = DocListCast(workspaces.data).map((doc: Doc, index: any) => { - return ( -