From 3d2bdbc23b352120c2549775afb702d96f57721b Mon Sep 17 00:00:00 2001 From: Salah Benmoussati <51402489+sbenmoussati@users.noreply.github.com> Date: Wed, 19 Jan 2022 09:23:24 +0100 Subject: [PATCH] SDA-3534 Snipping tool width shouldn't be greater than screen width and height (#1325) --- src/app/window-handler.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/app/window-handler.ts b/src/app/window-handler.ts index 1106f5ef..c50dc69a 100644 --- a/src/app/window-handler.ts +++ b/src/app/window-handler.ts @@ -1172,9 +1172,7 @@ export class WindowHandler { // Snipping tool height shouldn't be greater than min of screen width and height (screen orientation can be portrait or landscape) const minSize = Math.min(workAreaSize.width, workAreaSize.height); const maxToolHeight = Math.floor(calculatePercentage(minSize, 90)); - const maxToolWidth = Math.floor( - calculatePercentage(workAreaSize.width, 90), - ); + const maxToolWidth = Math.floor(calculatePercentage(minSize, 90)); const availableAnnotateAreaHeight = maxToolHeight - BUTTON_BARS_HEIGHT; const availableAnnotateAreaWidth = maxToolWidth; const scaleFactor = display.scaleFactor;