update:优化
This commit is contained in:
parent
442387922b
commit
a303eabc9c
@ -67,19 +67,18 @@ namespace Wpf_AiSportsMicrospace
|
||||
ProgressColor2 = "#215bc7"
|
||||
});
|
||||
|
||||
// 为了演示 5 个入口,这里复用前面 3 张图补足到 5 张
|
||||
coverFlow.Images.Add(new CoverFlowItem
|
||||
{
|
||||
ImageUri = GetResourceUri("new/home/card_4.png"),
|
||||
ProgressColor1 = "#215bc7",
|
||||
ProgressColor2 = "#fc640e",
|
||||
});
|
||||
coverFlow.Images.Add(new CoverFlowItem
|
||||
{
|
||||
ImageUri = GetResourceUri("new/home/card_5.png"),
|
||||
ProgressColor1 = "#e73d42",
|
||||
ProgressColor2 = "#fd8212"
|
||||
});
|
||||
//coverFlow.Images.Add(new CoverFlowItem
|
||||
//{
|
||||
// ImageUri = GetResourceUri("new/home/card_5.png"),
|
||||
// ProgressColor1 = "#e73d42",
|
||||
// ProgressColor2 = "#fd8212"
|
||||
//});
|
||||
|
||||
// 默认选中第3张
|
||||
coverFlow.SelectedIndex = 0;
|
||||
|
||||
@ -110,6 +110,8 @@ namespace Views.JumpLong
|
||||
// 举左手逻辑,例如结束动画或退出
|
||||
if (isBack) return; // 已经返回过主页了,避免重复执行
|
||||
_mainWin.HumanFrameUpdated -= this.OnFrameUpdated;
|
||||
_mainWin.FacialRecognitionEvent -= this.HumanPredicting;
|
||||
|
||||
isBack = true;
|
||||
var newPage = new Home();
|
||||
_mainWin?.SwitchPageWithMaskAnimation(newPage, true);
|
||||
@ -278,8 +280,6 @@ namespace Views.JumpLong
|
||||
//centerImg3.Opacity = 1;
|
||||
_sportType = 2;
|
||||
RankingGrid.BeginAnimation(UIElement.OpacityProperty, fadeInAnimation);
|
||||
ImageBehavior.SetRepeatBehavior(centerImg4, new RepeatBehavior(2));
|
||||
ImageBehavior.SetRepeatBehavior(centerImg4, new RepeatBehavior(1));
|
||||
ImageBehavior.GetAnimationController(centerImg4).Pause();
|
||||
|
||||
|
||||
@ -291,13 +291,18 @@ namespace Views.JumpLong
|
||||
if (i == 8)
|
||||
{
|
||||
centerImg4.Visibility = Visibility.Hidden;
|
||||
ImageBehavior.SetRepeatBehavior(centerImg4, new RepeatBehavior(2));
|
||||
ImageBehavior.SetRepeatBehavior(centerImg4, new RepeatBehavior(1));
|
||||
//centerImg3.Visibility = Visibility.Visible;
|
||||
}
|
||||
if (i == 1)
|
||||
{
|
||||
centerImg4.Visibility = Visibility.Visible;
|
||||
RankingGrid.BeginAnimation(UIElement.OpacityProperty, fadeInAnimation1);
|
||||
_sportType = 0;
|
||||
PlayMusic("raisehand.mp3");
|
||||
ShowCenterTip(TimeSpan.FromSeconds(3));
|
||||
|
||||
}
|
||||
await Task.Delay(1000);
|
||||
}
|
||||
@ -528,9 +533,9 @@ namespace Views.JumpLong
|
||||
{
|
||||
|
||||
Utils.PlayBackgroundMusic("countdown_3.mp3", false);
|
||||
_mainWin.ShowCountDownAnimation();
|
||||
// _mainWin.ShowCountDownAnimation();
|
||||
//centerImg3.Visibility = Visibility.Hidden;
|
||||
centerImg4.Visibility = Visibility.Visible;
|
||||
// centerImg4.Visibility = Visibility.Visible;
|
||||
//if (_sport?.IsCounting == true)
|
||||
//_mainWin.WebcamClient.OnExtractFrame += this.OnFrameExtracted;
|
||||
}
|
||||
|
||||
@ -251,7 +251,8 @@ namespace Views.SquatFu
|
||||
private DateTime _lastUpdateTime = DateTime.Now;
|
||||
private async void StartCountdown(int start = 3)
|
||||
{
|
||||
tipImage.Visibility = Visibility.Collapsed; // 隐藏提示图片
|
||||
tipImage.Visibility = Visibility.Hidden; // 隐藏提示图片
|
||||
tipImage.Opacity = 0;
|
||||
_currentGameState = GameState.Running;
|
||||
|
||||
_mainWin.ShowCountDownAnimation();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user