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

XAML Source generator incorrectly seals the codebehind class #2830

Closed
1 of 12 tasks
jeromelaban opened this issue Mar 18, 2020 · 0 comments · Fixed by #3036
Closed
1 of 12 tasks

XAML Source generator incorrectly seals the codebehind class #2830

jeromelaban opened this issue Mar 18, 2020 · 0 comments · Fixed by #3036
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. kind/bug Something isn't working

Comments

@jeromelaban
Copy link
Member

Current behavior

The code behind class of a XAML file is incorrectly marked as sealed by the source generator. This prevents inheriting from controls that define XAML.

Expected behavior

Even though the default WinUI 2 UserControl template does add a sealed specifier for a UserControl, removing it is possible; Uno should do the same.

Environment

Nuget Package: 2.2

Package Version(s):

Affected platform(s):

  • iOS
  • Android
  • WebAssembly
  • WebAssembly renderers for Xamarin.Forms
  • macOS
  • Windows
  • Build tasks
  • Solution Templates

Visual Studio:

  • 2017 (version: )
  • 2019 (version: )
  • for Mac (version: )

Relevant plugins:

  • Resharper (version: )

Anything else we need to know?

Addressing this issue requires to add a sample in the https://github.com/unoplatform/uno/tree/master/src/SourceGenerators/XamlGenerationTests project.

@jeromelaban jeromelaban added kind/bug Something isn't working good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. labels Mar 18, 2020
@jeromelaban jeromelaban changed the title XAML Source generator incorrectly seals the codebehing class XAML Source generator incorrectly seals the codebehind class Mar 18, 2020
jeromelaban added a commit that referenced this issue Apr 23, 2020
fix: Remove the sealed attribute from generated code (#2830)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. kind/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant