Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in preview5 #20

Closed
j4587698 opened this issue Feb 4, 2023 · 3 comments
Closed

Error in preview5 #20

j4587698 opened this issue Feb 4, 2023 · 3 comments

Comments

@j4587698
Copy link

j4587698 commented Feb 4, 2023

System.MethodAccessException: Attempt by method 'ReaderAvalonia.App.!XamlIlPopulate(System.IServiceProvider, ReaderAvalonia.App)' to access method 'CompiledAvaloniaXaml.!AvaloniaResources.Build:/Theme/Index.xaml(System.IServiceProvider)' failed.
   at ReaderAvalonia.App.!XamlIlPopulate(IServiceProvider, App) in App.axaml:line 11
   at ReaderAvalonia.App.!XamlIlPopulateTrampoline(App)
   at ReaderAvalonia.App.Initialize() in App.axaml.cs:line 16
   at Avalonia.AppBuilder.Setup() in /_/src/Avalonia.Controls/AppBuilder.cs:line 248
   at Avalonia.AppBuilder.SetupWithLifetime(IApplicationLifetime lifetime) in /_/src/Avalonia.Controls/AppBuilder.cs:line 160
   at Avalonia.ClassicDesktopStyleApplicationLifetimeExtensions.StartWithClassicDesktopLifetime(AppBuilder builder, String[] args, ShutdownMode shutdownMode) in /_/src/Avalonia.Controls/ApplicationLifetimes/ClassicDesktopStyleApplicationLifetime.cs:line 211

preview5 maybe modify something...

@kikipoulet
Copy link
Owner

kikipoulet commented Feb 5, 2023

Absolutely preview5 has some breaking changes.
I quickly checked and for example I have to remove all "ItemTemplate" and "Items" properties from ItemsPresenter, and it works the same, don't know why ._.

Edit : AvaloniaUI/Avalonia#9677

I will make the changes and create a new nuget package this week from preview1 to preview5 to be up-to-date. But I don't want to go too fast because I have to update the documentation because of the new "InteractiveContainer" control that changes and simplify the way to show Dialog and Toast for Desktop and Mobile, which was a horrible duplication of code before.

By the way this "InteractiveContainer" should be a good way to add some interactivity features. Dialog and Toast already, but maybe more soon - Notification, SnackBar, BottomSheet, ..

@j4587698
Copy link
Author

j4587698 commented Feb 6, 2023

@kikipoulet This is definitely good news.
I'm also waiting new InteractiveContainer,because sometimes I can't use DesktopPage but want to use Dialog.

@kikipoulet
Copy link
Owner

Suki 4.6.0 nuget package is uploaded and works with preview5 now.
I also updated the documentation because using Dialog and Toast is different now.

About InteractiveContainer; there are still two main limitations now :

  • you can only have one in your App, in your MainWindow/MainView
  • Dialog can't be stacked, you can't call a dialog inside a dialog. (Well, original dialog will be replaced). It can be a problem while using some Mobile Controls, a Picker can't be called from a Dialog right now for example.

I'm planning to solve these two limitations someday, but not immediately, so it is just for informations purpose 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants