From 23df0fde7a62a1bd2169d566d6f542af230ca23c Mon Sep 17 00:00:00 2001 From: Anton Vorobev Date: Mon, 23 Dec 2024 09:50:40 +0000 Subject: [PATCH] Pull request #5411: Bugfix/DXCF-5718 chart drawings unhide all drawings button is visible while nothing to unhide Merge in DXCHARTS/dxchart5 from bugfix/DXCF-5718-chart-drawings-unhide-all-drawings-button-is-visible-while-nothing-to-unhide to master * commit '76ebc09bd7d3b86b29787233ba0a68e173471517': [DXCF-5718] Chart Drawings - Unhide all drawings button is visible while nothing to unhide // copy [DXCF-5718] Chart Drawings - Unhide all drawings button is visible while nothing to unhide // init [DXCF-5718] Chart Drawings - Unhide all drawings button is visible while nothing to unhide // init GitOrigin-RevId: 62f7973fb076a46835ef87b1ad3ec7d1c99cbced --- src/chart/canvas/canvas-bounds-container.ts | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/chart/canvas/canvas-bounds-container.ts b/src/chart/canvas/canvas-bounds-container.ts index ddb0155..2a02b5b 100644 --- a/src/chart/canvas/canvas-bounds-container.ts +++ b/src/chart/canvas/canvas-bounds-container.ts @@ -1,8 +1,3 @@ -/* - * Copyright (C) 2019 - 2024 Devexperts Solutions IE Limited - * This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. - * If a copy of the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/. - */ /* * Copyright (C) 2019 - 2024 Devexperts Solutions IE Limited * This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. @@ -560,11 +555,11 @@ export class CanvasBoundsContainer { } //#region chart height ratio logic - if (this.graphsHeightRatio[CHART_UUID] === 0) { + if (!this.graphsHeightRatio[CHART_UUID] || this.graphsHeightRatio[CHART_UUID] === 0) { chartRatio = 0; } - if (this.graphsHeightRatio[CHART_UUID] !== 0) { + if (this.graphsHeightRatio[CHART_UUID] && this.graphsHeightRatio[CHART_UUID] !== 0) { if (paneIsAdded) { chartRatio = 1 * ratioForOldPec; } else {