Debian Codegraph @

modules/mono/editor/Godot.NET.Sdk/Godot.SourceGenerators.Tests/TestData/GeneratedSources/ExportedToolButtons_ScriptProperties.generated.cs

raw symbols SCIP
1 using Godot;
2 using Godot.NativeInterop;
3
4 partial class ExportedToolButtons
5 {
6 #pragma warning disable CS0109 // Disable warning about redundant 'new' keyword
7 /// <summary>
8 /// Cached StringNames for the properties and fields contained in this class, for fast lookup.
9 /// </summary>
10 public new class PropertyName : global::Godot.GodotObject.PropertyName {
11 /// <summary>
12 /// Cached name for the 'MyButton1' property.
13 /// </summary>
14 public new static readonly global::Godot.StringName @MyButton1 = "MyButton1";
15 /// <summary>
16 /// Cached name for the 'MyButton2' property.
17 /// </summary>
18 public new static readonly global::Godot.StringName @MyButton2 = "MyButton2";
19 }
20 /// <inheritdoc/>
21 [global::System.ComponentModel.EditorBrowsable(global::System.ComponentModel.EditorBrowsableState.Never)]
22 protected override bool GetGodotClassPropertyValue(in godot_string_name name, out godot_variant value)
23 {
24 if (name == PropertyName.@MyButton1) {
25 value = global::Godot.NativeInterop.VariantUtils.CreateFrom<global::Godot.Callable>(this.@MyButton1);
26 return true;
27 }
28 if (name == PropertyName.@MyButton2) {
29 value = global::Godot.NativeInterop.VariantUtils.CreateFrom<global::Godot.Callable>(this.@MyButton2);
30 return true;
31 }
32 return base.GetGodotClassPropertyValue(name, out value);
33 }
34 /// <summary>
35 /// Get the property information for all the properties declared in this class.
36 /// This method is used by Godot to register the available properties in the editor.
37 /// Do not call this method.
38 /// </summary>
39 [global::System.ComponentModel.EditorBrowsable(global::System.ComponentModel.EditorBrowsableState.Never)]
40 internal new static global::System.Collections.Generic.List<global::Godot.Bridge.PropertyInfo> GetGodotPropertyList()
41 {
42 var properties = new global::System.Collections.Generic.List<global::Godot.Bridge.PropertyInfo>();
43 properties.Add(new(type: (global::Godot.Variant.Type)25, name: PropertyName.@MyButton1, hint: (global::Godot.PropertyHint)39, hintString: "Click me!", usage: (global::Godot.PropertyUsageFlags)4, exported: true));
44 properties.Add(new(type: (global::Godot.Variant.Type)25, name: PropertyName.@MyButton2, hint: (global::Godot.PropertyHint)39, hintString: "Click me!,ColorRect", usage: (global::Godot.PropertyUsageFlags)4, exported: true));
45 return properties;
46 }
47 #pragma warning restore CS0109
48 }