Browse Source

Final review fixes.

pull/3055/head
Dariusz Komosinski 7 years ago
parent
commit
d2dbc12ee8
  1. 36
      src/Avalonia.Base/AvaloniaObject.cs

36
src/Avalonia.Base/AvaloniaObject.cs

@ -333,17 +333,12 @@ namespace Avalonia
throw new ArgumentException($"The property {property.Name} is readonly.");
}
if (Logger.TryGet(LogEventLevel.Verbose, out var logger))
{
var description = GetDescription(source);
logger.Log(
LogArea.Property,
this,
"Bound {Property} to {Binding} with priority LocalValue",
property,
description);
}
Logger.TryGet(LogEventLevel.Verbose)?.Log(
LogArea.Property,
this,
"Bound {Property} to {Binding} with priority LocalValue",
property,
GetDescription(source));
if (_directBindings == null)
{
@ -354,18 +349,13 @@ namespace Avalonia
}
else
{
if (Logger.TryGet(LogEventLevel.Verbose, out var logger))
{
var description = GetDescription(source);
logger.Log(
LogArea.Property,
this,
"Bound {Property} to {Binding} with priority {Priority}",
property,
description,
priority);
}
Logger.TryGet(LogEventLevel.Verbose)?.Log(
LogArea.Property,
this,
"Bound {Property} to {Binding} with priority {Priority}",
property,
GetDescription(source),
priority);
return Values.AddBinding(property, source, priority);
}

Loading…
Cancel
Save