Cleanup 5
This commit is contained in:
@@ -37,8 +37,7 @@ namespace FlaxEditor.Surface
|
||||
// Push clipping mask
|
||||
if (ClipChildren)
|
||||
{
|
||||
Rectangle clientArea;
|
||||
GetDesireClientArea(out clientArea);
|
||||
GetDesireClientArea(out Rectangle clientArea);
|
||||
Render2D.PushClip(ref clientArea);
|
||||
}
|
||||
|
||||
|
||||
@@ -54,8 +54,7 @@ namespace FlaxEditor.Surface
|
||||
return;
|
||||
|
||||
// Get or create context
|
||||
VisjectSurfaceContext surfaceContext;
|
||||
if (!_contextCache.TryGetValue(context, out surfaceContext))
|
||||
if (!_contextCache.TryGetValue(context, out VisjectSurfaceContext surfaceContext))
|
||||
{
|
||||
surfaceContext = CreateContext(_context, context);
|
||||
_context?.Children.Add(surfaceContext);
|
||||
@@ -119,8 +118,7 @@ namespace FlaxEditor.Surface
|
||||
}
|
||||
|
||||
// Check if has context in cache
|
||||
VisjectSurfaceContext surfaceContext;
|
||||
if (_contextCache.TryGetValue(context, out surfaceContext))
|
||||
if (_contextCache.TryGetValue(context, out VisjectSurfaceContext surfaceContext))
|
||||
{
|
||||
// Remove from navigation path
|
||||
while (ContextStack.Contains(surfaceContext))
|
||||
@@ -149,8 +147,7 @@ namespace FlaxEditor.Surface
|
||||
return;
|
||||
|
||||
// Check if already in a path
|
||||
VisjectSurfaceContext surfaceContext;
|
||||
if (_contextCache.TryGetValue(context, out surfaceContext) && ContextStack.Contains(surfaceContext))
|
||||
if (_contextCache.TryGetValue(context, out VisjectSurfaceContext surfaceContext) && ContextStack.Contains(surfaceContext))
|
||||
{
|
||||
// Change stack
|
||||
do
|
||||
|
||||
@@ -980,10 +980,10 @@ namespace FlaxEditor.Surface
|
||||
/// <inheritdoc />
|
||||
public override void OnLayoutDeserialize(XmlElement node)
|
||||
{
|
||||
float value1;
|
||||
|
||||
if (float.TryParse(node.GetAttribute("Split1"), out value1))
|
||||
if (float.TryParse(node.GetAttribute("Split1"), out float value1))
|
||||
_split1.SplitterValue = value1;
|
||||
|
||||
if (float.TryParse(node.GetAttribute("Split2"), out value1))
|
||||
_split2.SplitterValue = value1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user