private void ZoomOut(bool animated) { if (data.chartData.x == null) { return; } chartHeaderView.zoomOut(chartView, animated); //chartView.legendSignatureView.chevron.setAlpha(1f); zoomedChartView.SetHeader(null); long d = chartView.GetSelectedDate(); data.activeZoom = 0; //chartView.Visibility = Visibility.Visible; zoomedChartView.ClearSelection(); zoomedChartView.SetHeader(null); chartView.SetHeader(chartHeaderView); if (!animated) { zoomedChartView.Visibility = Visibility.Collapsed; //chartView.enabled = true; //zoomedChartView.enabled = false; chartView.Invalidate(); //((Activity)getContext()).getWindow().clearFlags(WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE); //for (CheckBoxHolder checkbox : checkBoxes) //{ // checkbox.checkBox.setAlpha(1); // checkbox.checkBox.enabled = true; //} } else { ValueAnimator animator = CreateTransitionAnimator(d, false); animator.AddListener(new AnimatorUpdateListener(animator => { _ = zoomedChartView.Dispatcher.RunAsync(Windows.UI.Core.CoreDispatcherPriority.Normal, () => { zoomedChartView.Visibility = Visibility.Collapsed; }); chartView.transitionMode = BaseChartView.TRANSITION_MODE_NONE; zoomedChartView.transitionMode = BaseChartView.TRANSITION_MODE_NONE; //chartView.enabled = true; //zoomedChartView.enabled = false; if (chartView is not StackLinearChartView) { chartView.legendShowing = true; chartView.MoveLegend(); chartView.AnimateLegend(true); chartView.Invalidate(); } else { chartView.legendShowing = false; chartView.ClearSelection(); } //((Activity)getContext()).getWindow().clearFlags(WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE); })); //for (CheckBoxHolder checkbox : checkBoxes) //{ // checkbox.checkBox.animate().alpha(1f).start(); // checkbox.checkBox.enabled = true; //} animator.Start(); } }