-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Closed
Labels
area-xamlXAML, CSS, Triggers, BehaviorsXAML, CSS, Triggers, Behaviorsfixed-in-8.0.10fixed-in-9.0.0-preview.2.10293i/regressionThis issue described a confirmed regression on a currently supported versionThis issue described a confirmed regression on a currently supported versionpartnerIssue or Request from a partner teamIssue or Request from a partner teamplatform/androidplatform/iosplatform/macosmacOS / Mac CatalystmacOS / Mac Catalystplatform/windowss/needs-attentionIssue has more information and needs another lookIssue has more information and needs another lookt/bugSomething isn't workingSomething isn't working
Milestone
Description
Description
I have created a Maui library project file to add a custom resource dictionary for theme support. Then, I included it in the application file and added the custom resource dictionary to the merged dictionaries like below. I'm getting AccessViolationException when I run the application in release mode only. And the example deployed successfully with debug mode. I have attached the runnable example with the library project.
<Application xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:local="clr-namespace:CustomThemeTesting"
xmlns:theme="clr-namespace:ThemeLibrary;assembly=ThemeLibrary"
x:Class="CustomThemeTesting.App">
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Resources/Styles/Colors.xaml" />
<ResourceDictionary Source="Resources/Styles/Styles.xaml" />
<theme:CustomThemeResourceDictionary VisualTheme="LightDefault"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Application.Resources>
</Application>
Steps to Reproduce
- Download and extract the attached example.
- Run the CustomThemeTesting project with release mode. You will get the access violation exception.
Link to public reproduction project repository
No response
Version with bug
8.0.3
Is this a regression from previous behavior?
Not sure, did not test other versions
Last version that worked well
Unknown/Other
Affected platforms
iOS, Android, Windows, macOS
Affected platform versions
No response
Did you find any workaround?
No response
Relevant log output
No response
ardalis
Metadata
Metadata
Assignees
Labels
area-xamlXAML, CSS, Triggers, BehaviorsXAML, CSS, Triggers, Behaviorsfixed-in-8.0.10fixed-in-9.0.0-preview.2.10293i/regressionThis issue described a confirmed regression on a currently supported versionThis issue described a confirmed regression on a currently supported versionpartnerIssue or Request from a partner teamIssue or Request from a partner teamplatform/androidplatform/iosplatform/macosmacOS / Mac CatalystmacOS / Mac Catalystplatform/windowss/needs-attentionIssue has more information and needs another lookIssue has more information and needs another lookt/bugSomething isn't workingSomething isn't working
Type
Projects
Status
Done