38 references to CreateLogger
Microsoft.Maui.Controls (38)
Application\Application.cs (1)
420
_logger ??= Handler?.MauiContext?.
CreateLogger
<Application>();
BindableObject.cs (7)
89
Application.Current?.FindMauiContext()?.
CreateLogger
<BindableObject>()?.LogWarning($"Cannot set the BindableProperty \"{property.PropertyName}\" because it is readonly.");
103
Application.Current?.FindMauiContext()?.
CreateLogger
<BindableObject>()?.LogWarning($"Cannot set the BindableProperty \"{property.PropertyName}\" because it is readonly.");
298
Application.Current?.FindMauiContext()?.
CreateLogger
<BindableObject>()?.LogWarning($"Cannot set the a OneWay Binding \"{targetProperty.PropertyName}\" because it is readonly.");
493
Application.Current?.FindMauiContext()?.
CreateLogger
<BindableObject>()?.LogWarning($"Cannot set the BindableProperty \"{property.PropertyName}\" because it is readonly.");
521
Application.Current?.FindMauiContext()?.
CreateLogger
<BindableObject>()?.LogWarning($"Cannot set the BindableProperty \"{property.PropertyName}\" because it is readonly.");
562
Application.Current?.FindMauiContext()?.
CreateLogger
<BindableObject>()?.LogWarning($"Cannot convert {value} to type '{property.ReturnType}'");
568
Application.Current?.FindMauiContext()?.
CreateLogger
<BindableObject>()?.LogWarning($"Value is an invalid value for {property.PropertyName}");
BindablePropertyConverter.cs (2)
84
Application.Current?.FindMauiContext()?.
CreateLogger
<BindablePropertyConverter>()?.LogWarning("Can't resolve properties with xml namespace prefix.");
90
Application.Current?.FindMauiContext()?.
CreateLogger
<BindablePropertyConverter>()?.LogWarning($"Can't resolve {value}. Accepted syntax is Type.PropertyName.");
BindingBase.cs (2)
157
Application.Current?.FindMauiContext()?.
CreateLogger
<BindingBase>()?.LogWarning("FormatException");
172
Application.Current?.FindMauiContext()?.
CreateLogger
<BindingBase>()?.LogWarning("FormatException");
Element\Element.cs (3)
299
.
CreateLogger
<Element>()?
354
.
CreateLogger
<Element>()?
409
Application.Current?.FindMauiContext()?.
CreateLogger
<Element>()?.LogWarning($"{this} is already a child of {element}. Remove {this} from {element} before adding to {value}.");
Interactivity\EventTrigger.cs (1)
85
Application.Current?.FindMauiContext()?.
CreateLogger
<EventTrigger>()?.LogWarning("Cannot attach EventTrigger to {Type}.{Event}. Check if the handler exists and if the signature is right.", bindable.GetType(), Event);
ListView\ListView.cs (2)
638
Application.Current?.FindMauiContext()?.
CreateLogger
<ListView>()?.LogWarning("GroupHeaderTemplate and GroupDisplayBinding cannot be set at the same time, setting GroupHeaderTemplate to null");
648
Application.Current?.FindMauiContext()?.
CreateLogger
<ListView>()?.LogWarning("GroupHeaderTemplate and GroupDisplayBinding cannot be set at the same time, setting GroupDisplayBinding to null");
MergedStyle.cs (1)
49
Application.Current?.FindMauiContext()?.
CreateLogger
<Style>()?.LogWarning("Style TargetType {FullName} is not compatible with element target type {TargetType}", value.TargetType.FullName, TargetType);
NavigationPage\NavigationPage.cs (2)
241
Application.Current?.FindMauiContext()?.
CreateLogger
<NavigationPage>()?.LogWarning(e, null);
881
Application.Current?.FindMauiContext()?.
CreateLogger
<NavigationPage>()?.LogWarning("RemovePage called for CurrentPage object. This can result in undesired behavior, consider calling PopAsync instead.");
NavigationPage\NavigationPage.Legacy.cs (1)
241
Application.Current?.FindMauiContext()?.
CreateLogger
<NavigationPage>()?.LogWarning("RemovePage called for CurrentPage object. This can result in undesired behavior, consider calling PopAsync instead.");
RadioButton\RadioButton.cs (1)
638
Application.Current?.FindMauiContext()?.
CreateLogger
<RadioButton>()?.LogWarning("Warning - {RuntimePlatform} does not support View as the {PropertyName} property of RadioButton; the return value of the ToString() method will be displayed instead.", DeviceInfo.Platform, ContentProperty.PropertyName);
Shell\Shell.cs (2)
1258
Application.Current?.FindMauiContext()?.
CreateLogger
<Shell>()?.LogWarning(exc, "If you're using hot reload add a route to everything in your shell file");
1554
Application.Current?.FindMauiContext()?.
CreateLogger
<Shell>()?.LogWarning(exc, "Failed to Navigate Back");
Shell\ShellSection.cs (1)
490
Application.Current?.FindMauiContext()?.
CreateLogger
<ShellSection>()?.LogWarning("Failed to Create Content For: {route}", route);
StreamWrapper.cs (1)
98
Application.Current?.FindMauiContext()?.
CreateLogger
<StreamWrapper>()?
UriImageSource.cs (2)
75
Application.Current?.FindMauiContext()?.
CreateLogger
<UriImageSource>()?.LogWarning(ex, "Error getting stream for {Uri}", Uri);
126
Application.Current?.FindMauiContext()?.
CreateLogger
<UriImageSource>()?.LogWarning(ex, "Error getting stream for {Uri}", Uri);
ViewExtensions.cs (1)
322
element.FindMauiContext(fallbackToAppMauiContext)?.
CreateLogger
<T>();
Visuals\VisualMarker.cs (1)
29
var logger = Application.Current?.FindMauiContext()?.
CreateLogger
<IVisual>();
Visuals\VisualTypeConverter.cs (5)
86
Application.Current?.FindMauiContext()?.
CreateLogger
<IVisual>()?.LogWarning("Cannot scan assembly {assembly} for Visual types.", assembly.FullName);
90
Application.Current?.FindMauiContext()?.
CreateLogger
<IVisual>()?.LogWarning("Unable to load a dependent assembly for {assembly}. It cannot be scanned for Visual types.", assembly.FullName);
94
Application.Current?.FindMauiContext()?.
CreateLogger
<IVisual>()?.LogWarning("Unable to load a dependent assembly for {assembly}. Types cannot be loaded.", assembly.FullName);
146
Application.Current?.FindMauiContext()?.
CreateLogger
<IVisual>()?.LogWarning("Unable to register {visualType} please add a public default constructor", visualType.ToString());
165
Application.Current?.FindMauiContext()?.
CreateLogger
<IVisual>()?.LogWarning(
Xaml\Diagnostics\BindingDiagnostics.cs (2)
18
Application.Current?.FindMauiContext()?.
CreateLogger
<BindingDiagnostics>()?.LogWarning(message, messageArgs);
24
Application.Current?.FindMauiContext()?.
CreateLogger
<BindingDiagnostics>()?.LogWarning(message, messageArgs);