Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
using Microsoft.UI.Xaml.Data;
using Microsoft.UI.Xaml.Input;
using Microsoft.UI.Xaml.Media;
using Microsoft.Maui.ApplicationModel;
using Windows.Foundation;
using Specifics = Microsoft.Maui.Controls.PlatformConfiguration.WindowsSpecific.ListView;
using UwpScrollBarVisibility = Microsoft.UI.Xaml.Controls.ScrollBarVisibility;
Expand Down Expand Up @@ -597,12 +598,12 @@ async void ScrollTo(object group, object item, ScrollToPosition toPosition, bool
if (viewer == null)
{
RoutedEventHandler loadedHandler = null;
loadedHandler = async (o, e) =>
loadedHandler = (o, e) =>
{
List.Loaded -= loadedHandler;

// Here we try to avoid an exception, see explanation at bottom
await Control.Dispatcher.RunIdleAsync(args => { ScrollTo(group, item, toPosition, shouldAnimate, includeGroup); });
MainThread.BeginInvokeOnMainThread(() => { ScrollTo(group, item, toPosition, shouldAnimate, includeGroup); });
};
List.Loaded += loadedHandler;
return;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#if TEST_FAILS_ON_WINDOWS //App was crashing while open on windows, getting Object Null Reference exception on ListViewRenderer, issue: https://github.com/dotnet/maui/issues/26345
using NUnit.Framework;
using NUnit.Framework;
using UITest.Appium;
using UITest.Core;

Expand All @@ -22,5 +21,4 @@ public void Bugzilla42956Test()
App.WaitForElement(Success);
}
}
}
#endif
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#if TEST_FAILS_ON_WINDOWS && TEST_FAILS_ON_CATALYST // In Windows, getting object null reference exception while running the sample, Issue: https://github.com/dotnet/maui/issues/26345
//In MacCatalyst, Timeout Exception in the label line no 20. tried by using App.QueryUntilPresent, and adding delay also won't work.
#if TEST_FAILS_ON_CATALYST //In MacCatalyst, Timeout Exception in the label line no 20. tried by using App.QueryUntilPresent, and adding delay also won't work.
using NUnit.Framework;
using UITest.Appium;
using UITest.Core;
Expand Down