mirror of
https://github.com/Stone-Red-Code/docs-desktop.git
synced 2026-09-04 09:06:04 +02:00
Fix code bug in markup extensions (#1097)
* Update service-contexts-with-type-converters-and-markup-extensions.md * Apply suggestions from code review Co-authored-by: David Pine <[email protected]> Co-authored-by: David Pine <[email protected]>
This commit is contained in:
co-authored by
David Pine
parent
e7f2ff0e96
commit
d9b54ba15b
+4
-4
@@ -19,7 +19,7 @@ As an implementer of a value converter, you often need access to some type of co
|
||||
```csharp
|
||||
public override object ProvideValue(IServiceProvider serviceProvider)
|
||||
{
|
||||
...
|
||||
//...
|
||||
// Get the IXamlTypeResolver from the service provider
|
||||
if (serviceProvider == null)
|
||||
{
|
||||
@@ -27,10 +27,10 @@ public override object ProvideValue(IServiceProvider serviceProvider)
|
||||
}
|
||||
IXamlTypeResolver xamlTypeResolver = serviceProvider.GetService(typeof(IXamlTypeResolver)) as IXamlTypeResolver;
|
||||
if (xamlTypeResolver == null)
|
||||
{
|
||||
throw new ArgumentException("IXamlTypeResolver"));
|
||||
{
|
||||
throw new ArgumentException("IXamlTypeResolver");
|
||||
}
|
||||
...
|
||||
//...
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user