protected override async Task OnAppearingAnimationEndAsync() { if (!IsAnimationEnabled) { return; } var translateLength = 400u; await Task.WhenAll( mapNameLabel.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), mapNameLabel.FadeTo(1), (new Func <Task>(async() => { await Task.Delay(200); await Task.WhenAll( FileNameEntry.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), FileNameEntry.FadeTo(1)); }))()); await Task.WhenAll( SaveButton.ScaleTo(1), SaveButton.FadeTo(1)); }
protected override async Task OnDisappearingAnimationBeginAsync() { if (!IsAnimationEnabled) { return; } var taskSource = new TaskCompletionSource <bool>(); var currentHeight = FrameContainer.Height; await Task.WhenAll( mapNameLabel.FadeTo(0), FileNameEntry.FadeTo(0), SaveButton.FadeTo(0)); FrameContainer.Animate("HideAnimation", d => { FrameContainer.HeightRequest = d; }, start: currentHeight, end: 170, finished: async(d, b) => { await Task.Delay(300); taskSource.TrySetResult(true); }); await taskSource.Task; }
protected override async Task OnAppearingAnimationEndAsync() { if (!IsAnimationEnabled) { return; } var translateLength = 400u; await Task.WhenAll( HabitEntry.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), HabitEntry.FadeTo(1), DescriptionLabel.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), DescriptionLabel.FadeTo(1), DescriptionEditor.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), DescriptionEditor.FadeTo(1), StartPicker.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), StartPicker.FadeTo(1), EndPicker.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), EndPicker.FadeTo(1), AmountEntry.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), AmountEntry.FadeTo(1), UnitEntry.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), UnitEntry.FadeTo(1) //(new Func<Task>(async () => //{ // await Task.Delay(300); // await Task.WhenAll( // //RememberCheckBox.TranslateTo(0, 0, easing: Easing.SpringOut, length: translateLength), // //RememberCheckBox.FadeTo(1) // ); //}))() ); await Task.WhenAll( EditButton.ScaleTo(1), EditButton.FadeTo(1), SaveButton.ScaleTo(1), SaveButton.FadeTo(1), DeleteButton.ScaleTo(1), DeleteButton.FadeTo(1) ); }