Skip to content

Commit

Permalink
feat: Remove unnecessary base type (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
noliar authored Jul 23, 2024
1 parent 124b554 commit b348405
Show file tree
Hide file tree
Showing 41 changed files with 4,899 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public static string GenerateAttachedDependencyProperty(ClassData @class, Depend
namespace {@class.Namespace}
{{
{GenerateModifiers(@class)}partial class {@class.Name}{GenerateBaseType(@class)}
{GenerateModifiers(@class)}partial class {@class.Name}
{{
{GenerateXmlDocumentationFrom(property.XmlDocumentation, property, isProperty: false)}
{GenerateGeneratedCodeAttribute(@class.Version)}
Expand Down Expand Up @@ -105,14 +105,4 @@ private static string GenerateModifiers(ClassData @class)

return @class.Modifiers;
}

private static string GenerateBaseType(ClassData @class)
{
if (@class.Framework == Framework.Avalonia)
{
return $" : {GenerateTypeByPlatform(@class.Framework, "AvaloniaObject")}";
}

return string.Empty;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace H.Generators.IntegrationTests
{
partial class GridExtensions : global::Avalonia.AvaloniaObject
partial class GridExtensions
{
/// <summary>
/// Identifies the SomeProperty dependency property.<br/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace H.Generators.IntegrationTests
{
partial class GridExtensions : global::Avalonia.AvaloniaObject
partial class GridExtensions
{
/// <summary>
/// Identifies the AttachedReadOnlyProperty dependency property.<br/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace H.Generators.IntegrationTests
{
partial class UIElementExtensions : global::Avalonia.AvaloniaObject
partial class UIElementExtensions
{
/// <summary>
/// Identifies the BindEventProperty dependency property.<br/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace H.Generators.IntegrationTests
{
partial class GridHelpers : global::Avalonia.AvaloniaObject
partial class GridHelpers
{
/// <summary>
/// Identifies the RowCount dependency property.<br/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace H.Generators.IntegrationTests
{
partial class TreeViewExtensions : global::Avalonia.AvaloniaObject
partial class TreeViewExtensions
{
/// <summary>
/// Identifies the Mode dependency property.<br/>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[
{
Id: CS8019,
Title: Unnecessary using directive,
Severity: Hidden,
WarningLevel: 1,
Location: : (0,0)-(0,15),
HelpLink: https://msdn.microsoft.com/query/roslyn.query?appId=roslyn&k=k(CS8019),
MessageFormat: Unnecessary using directive.,
Message: Unnecessary using directive.,
Category: Compiler,
CustomTags: [
Compiler,
Telemetry
]
}
]
Loading

0 comments on commit b348405

Please sign in to comment.