await MaterialDialog.Instance.AlertAsync not waiting
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 55/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 停滞
- 技術スタック
- csharp
- 領域
- mobile-dev
調査の方向性
XF.Material/UI/Dialogs/MaterialAlertDialog.xaml.cs の、issue でリンクされている AlertAsync と ConfirmAsync の実装から始め、それぞれのメソッドが返す task を比較します。AlertAsync で Android の動作を再現し、ダイアログが閉じられた後にのみ呼び出し元が再開することを確認します。AlertAsync が ConfirmAsync と同様に待機すれば完了です。
索引モデルが issue の本文から書いたものです。
説明
🐛 Bug Report
A call to await MaterialDialog.Instance.AlertAsync does not wait unitl the dialog's dismiss before continuing.
Doing some tests, calling var msgResult = await MaterialDialog.Instance.ConfirmAsync actually waits so I looked at the code to see what the differences are.
I think the problem is due to the way the dialog is shown on the AlertAsync: in AlertAsync the task returned is the one from await dialog.ShowAsync
https://github.com/Baseflow/XF-Material-Library/blob/589fcf485576d2717e6090789aeb17ed75e2a140/XF.Material/UI/Dialogs/MaterialAlertDialog.xaml.cs#L43
On ConfirmAsync the returned task is the one from InputTaskCompletionSource which is fired only after a button press
https://github.com/Baseflow/XF-Material-Library/blob/589fcf485576d2717e6090789aeb17ed75e2a140/XF.Material/UI/Dialogs/MaterialAlertDialog.xaml.cs#L61
For now a workaround is just to call ConfirmAsync instead of AlertAsync and setting dismissiveText to null, with this we have basically the same funcionality of AlertAsync.
Configuration
Version: 1.7.5
Platform:
- 📱 iOS
- 🤖 Android
- 🏁 WPF
- 🌎 UWP
- 🍎 MacOS
- 📺 tvOS
- 🐒 Xamarin.Forms
- 主要言語
- C#
- スター
- 633
- フォーク
- 150
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Baseflow/XF-Material-Library のほかの issue
-
.Net Maui Supportオープン
難易度 5/5 1週間以上 初心者へのやさしさ 20/100
Baseflow/XF-Material-Library#458 · コメント 1 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 50/100
Baseflow/XF-Material-Library#457 · コメント 1 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 48/100
Baseflow/XF-Material-Library#456 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
Baseflow/XF-Material-Library#454 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 58/100
Baseflow/XF-Material-Library#453 ·
Baseflow/XF-Material-Library の issue をすべて見る
似ている issue
-
agentic-workflows area/Docs partner/agentic-workflows
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
microsoft/fluentui-blazor#5364 ·
メンテナーはふだん 1 日以内に返信
-
.NET triage
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
microsoft/agent-framework#8811 ·
メンテナーはふだん 1 日以内に返信
-
.NET Docs
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
getsentry/sentry-dotnet#5637 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
QuantConnect/Lean#9842 ·
メンテナーはふだん 1 日以内に返信