From ba70b47fc11bccd0606b540101939bbb4b8cadca Mon Sep 17 00:00:00 2001 From: Relintai Date: Thu, 1 Jun 2023 17:18:30 +0200 Subject: [PATCH] Fixed the remaining issues. --- .../GodotTools/GodotTools/Build/BuildOutputView.cs | 12 ++++++------ editor/GodotTools/GodotTools/Build/MSBuildPanel.cs | 12 ++++++------ glue/GodotSharp/GodotSharp/Core/Projection.cs | 8 ++++---- glue/GodotSharp/GodotSharp/Core/Rect2i.cs | 6 +++--- glue/GodotSharp/GodotSharp/Core/StringName.cs | 6 +++--- 5 files changed, 22 insertions(+), 22 deletions(-) diff --git a/editor/GodotTools/GodotTools/Build/BuildOutputView.cs b/editor/GodotTools/GodotTools/Build/BuildOutputView.cs index 5974381..3e1425c 100644 --- a/editor/GodotTools/GodotTools/Build/BuildOutputView.cs +++ b/editor/GodotTools/GodotTools/Build/BuildOutputView.cs @@ -41,13 +41,13 @@ namespace GodotTools.Build get { if (!HasBuildExited) - return GetIcon("Stop", "EditorIcons"); + return GetThemeIcon("Stop", "EditorIcons"); if (BuildResult == Build.BuildResult.Error) - return GetIcon("Error", "EditorIcons"); + return GetThemeIcon("Error", "EditorIcons"); if (WarningCount > 1) - return GetIcon("Warning", "EditorIcons"); + return GetThemeIcon("Warning", "EditorIcons"); return null; } @@ -156,8 +156,8 @@ namespace GodotTools.Build { _issuesList.Clear(); - using (var warningIcon = GetIcon("Warning", "EditorIcons")) - using (var errorIcon = GetIcon("Error", "EditorIcons")) + using (var warningIcon = GetThemeIcon("Warning", "EditorIcons")) + using (var errorIcon = GetThemeIcon("Error", "EditorIcons")) { for (int i = 0; i < _issues.Count; i++) { @@ -345,7 +345,7 @@ namespace GodotTools.Build if (_issuesList.IsAnythingSelected()) { // Add menu entries for the selected item - _issuesListContextMenu.AddIconItem(GetIcon("ActionCopy", "EditorIcons"), + _issuesListContextMenu.AddIconItem(GetThemeIcon("ActionCopy", "EditorIcons"), label: "Copy Error".TTR(), (int)IssuesContextMenuOption.Copy); } diff --git a/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs b/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs index 4983864..091a15f 100644 --- a/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs +++ b/editor/GodotTools/GodotTools/Build/MSBuildPanel.cs @@ -116,7 +116,7 @@ namespace GodotTools.Build var toolBarHBox = new HBoxContainer { SizeFlagsHorizontal = (int)SizeFlags.ExpandFill }; AddChild(toolBarHBox); - _buildMenuBtn = new MenuButton { Text = "Build", Icon = GetIcon("Play", "EditorIcons") }; + _buildMenuBtn = new MenuButton { Text = "Build", Icon = GetThemeIcon("Play", "EditorIcons") }; toolBarHBox.AddChild(_buildMenuBtn); var buildMenu = _buildMenuBtn.GetPopup(); @@ -128,7 +128,7 @@ namespace GodotTools.Build _errorsBtn = new Button { HintTooltip = "Show Errors".TTR(), - Icon = GetIcon("StatusError", "EditorIcons"), + Icon = GetThemeIcon("StatusError", "EditorIcons"), ExpandIcon = false, ToggleMode = true, Pressed = true, @@ -140,7 +140,7 @@ namespace GodotTools.Build _warningsBtn = new Button { HintTooltip = "Show Warnings".TTR(), - Icon = GetIcon("NodeWarning", "EditorIcons"), + Icon = GetThemeIcon("NodeWarning", "EditorIcons"), ExpandIcon = false, ToggleMode = true, Pressed = true, @@ -170,11 +170,11 @@ namespace GodotTools.Build if (what == NotificationThemeChanged) { if (_buildMenuBtn != null) - _buildMenuBtn.Icon = GetIcon("Play", "EditorIcons"); + _buildMenuBtn.Icon = GetThemeIcon("Play", "EditorIcons"); if (_errorsBtn != null) - _errorsBtn.Icon = GetIcon("StatusError", "EditorIcons"); + _errorsBtn.Icon = GetThemeIcon("StatusError", "EditorIcons"); if (_warningsBtn != null) - _warningsBtn.Icon = GetIcon("NodeWarning", "EditorIcons"); + _warningsBtn.Icon = GetThemeIcon("NodeWarning", "EditorIcons"); } } } diff --git a/glue/GodotSharp/GodotSharp/Core/Projection.cs b/glue/GodotSharp/GodotSharp/Core/Projection.cs index 3fe9dd4..c3203be 100644 --- a/glue/GodotSharp/GodotSharp/Core/Projection.cs +++ b/glue/GodotSharp/GodotSharp/Core/Projection.cs @@ -41,10 +41,10 @@ namespace Godot public static Projection Identity { get { return _identity; } } public void set_identity() { - Row0[0] = 1; - Row1[1] = 1; - Row2[2] = 1; - Row3[3] = 1; + Row0.x = 1; + Row1.y = 1; + Row2.z = 1; + Row3.w = 1; } public Projection(Vector4 Row0, Vector4 Row1, Vector4 Row2, Vector4 Row3) { diff --git a/glue/GodotSharp/GodotSharp/Core/Rect2i.cs b/glue/GodotSharp/GodotSharp/Core/Rect2i.cs index 134109e..7a48f63 100644 --- a/glue/GodotSharp/GodotSharp/Core/Rect2i.cs +++ b/glue/GodotSharp/GodotSharp/Core/Rect2i.cs @@ -57,7 +57,7 @@ namespace Godot /// The position. /// The width. /// The height. - public Rect2i(Vector2i position, real_t width, real_t height) + public Rect2i(Vector2i position, int width, int height) { _position = position; _size = new Vector2i(width, height); @@ -69,7 +69,7 @@ namespace Godot /// The position's X coordinate. /// The position's Y coordinate. /// The size. - public Rect2i(real_t x, real_t y, Vector2i size) + public Rect2i(int x, int y, Vector2i size) { _position = new Vector2i(x, y); _size = size; @@ -82,7 +82,7 @@ namespace Godot /// The position's Y coordinate. /// The width. /// The height. - public Rect2i(real_t x, real_t y, real_t width, real_t height) + public Rect2i(int x, int y, int width, int height) { _position = new Vector2i(x, y); _size = new Vector2i(width, height); diff --git a/glue/GodotSharp/GodotSharp/Core/StringName.cs b/glue/GodotSharp/GodotSharp/Core/StringName.cs index 7154ad0..98a8bcc 100644 --- a/glue/GodotSharp/GodotSharp/Core/StringName.cs +++ b/glue/GodotSharp/GodotSharp/Core/StringName.cs @@ -62,7 +62,7 @@ namespace Godot } public StringName() { - ptr = godot_icall_StringName_Ctor(path); + ptr = godot_icall_StringName_Ctor(); } public StringName(string path) @@ -91,7 +91,7 @@ namespace Godot public static bool operator ==(StringName left, StringName right) { - return godot_icall_StringName_operator_String(StringName.GetPtr(left), StringName.GetPtr(right)); + return godot_icall_StringName_operator_Equals(StringName.GetPtr(left), StringName.GetPtr(right)); } public static bool operator !=(StringName left, StringName right) @@ -111,7 +111,7 @@ namespace Godot public bool Equals(StringName other) { - return godot_icall_StringName_operator_String(StringName.GetPtr(left), StringName.GetPtr(right)); + return godot_icall_StringName_operator_Equals(StringName.GetPtr(this), StringName.GetPtr(other)); } public override int GetHashCode()