This commit is contained in:
Wojtek Figat
2021-11-11 13:23:58 +01:00
parent 6f16195b08
commit ea80992376
3 changed files with 9 additions and 13 deletions

View File

@@ -244,7 +244,7 @@ namespace FlaxEditor.Surface.Archetypes
Title = "Mad",
Description = "Performs value multiplication and addition at once",
Flags = NodeFlags.AllGraphs,
Size = new Vector2(110, 60),
Size = new Vector2(160, 60),
ConnectionsHints = ConnectionsHint.Numeric,
IndependentBoxes = new[]
{

View File

@@ -169,8 +169,8 @@ namespace FlaxEngine.GUI
[NoSerialize, HideInEditor]
public float Width
{
get => _bounds.Width;
set => Bounds = new Rectangle(_bounds.Location, value, _bounds.Height);
get => _bounds.Size.X;
set => Bounds = new Rectangle(_bounds.Location, value, _bounds.Size.Y);
}
/// <summary>
@@ -179,8 +179,8 @@ namespace FlaxEngine.GUI
[NoSerialize, HideInEditor]
public float Height
{
get => _bounds.Height;
set => Bounds = new Rectangle(_bounds.Location, _bounds.Width, value);
get => _bounds.Size.Y;
set => Bounds = new Rectangle(_bounds.Location, _bounds.Size.X, value);
}
/// <summary>

View File

@@ -169,9 +169,6 @@ namespace FlaxEngine.GUI
/// <inheritdoc />
public override bool OnMouseDown(Vector2 location, MouseButton button)
{
if (base.OnMouseDown(location, button))
return true;
if (button == MouseButton.Left && _splitterRect.Contains(location))
{
// Start moving splitter
@@ -179,21 +176,20 @@ namespace FlaxEngine.GUI
Focus();
return false;
}
return false;
return base.OnMouseDown(location, button);
}
/// <inheritdoc />
public override bool OnMouseUp(Vector2 location, MouseButton button)
{
if (base.OnMouseUp(location, button))
return true;
if (_splitterClicked)
{
EndTracking();
return true;
}
return false;
return base.OnMouseUp(location, button);
}
/// <inheritdoc />