In This Article

FallbackParentControlDesignerProvider Class

Allows for a fallback ParentControlDesigner to be used when a specified designer is unavailable.

public sealed class FallbackParentControlDesignerProvider : TypeDescriptionProvider
Inheritance:
Object Object

Remarks

This prevents ComponentDesigner from taking effect when a specified designer is not found.

Constructors

FallbackParentControlDesignerProvider(TypeDescriptionProvider)

Initializes a new instance of the FallbackParentControlDesignerProvider class.

public FallbackParentControlDesignerProvider(TypeDescriptionProvider parent)
Parameter Type Description
parent TypeDescriptionProvider

The parent TypeDescriptionProvider.

Methods

GetTypeDescriptor(Type, Object)

Gets a custom type descriptor for the given type and object.

public override ICustomTypeDescriptor GetTypeDescriptor(Type objectType, object instance)
Parameter Type Description
objectType Type

The type of object for which to retrieve the type descriptor.

instance Object

An instance of the type.

Returns

ICustomTypeDescriptor:

An ICustomTypeDescriptor that can provide metadata for the type.

Register(Type)

Registers the provider.

public static void Register(Type type)
Parameter Type Description
type Type

The component Type.

Remarks

This method should only be called once per type.