1
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
2
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
5
* Currently known logged missing services for the Windows.Forms designer:
7
* System.ComponentModel.ContainerFilterService
8
* can modify (filter) a component collection
11
* System.ComponentModel.TypeDescriptionProvider
12
* can modify the type information of components at runtime
15
* System.ComponentModel.Design.DesignerCommandSet
16
* System.ComponentModel.Design.DesignerActionService
17
* System.ComponentModel.Design.DesignerActionUIService
18
* these seem to be added automatically when required
19
* for managing designer verbs and smart tags
21
* System.ComponentModel.Design.Serialization.ComponentCache
22
* added automatically at some stage during code generation
23
* by an internal code serializer class
25
* System.Windows.Forms.Design.IMenuEditorService
26
* required for editing .NET 1.x Menus (?), not supported by SharpDevelop
28
* System.Windows.Forms.Design.ISelectionUIService
29
* added automatically by ComponentDocumentDesigner or ComponentTray
31
* System.Windows.Forms.Design.IWindowsFormsEditorService
32
* provided by the PropertyGrid, the designer seems to find this somehow
35
* System.ComponentModel.Design.IDesignerEventService
36
* provided by the DesignSurfaceManager
37
* (this is only logged as missing because the DesignSurfaceManager tries the external service provider first)
40
* During unloading of the designer some standard services like IDesignerHost are
41
* logged as missing as they have already been removed. This is probably expected.
46
// Uncomment the following line to log all service requests
47
//#define WFDESIGN_LOG_SERVICE_REQUESTS
51
using System.ComponentModel.Design;
53
using ICSharpCode.Core;
55
namespace ICSharpCode.FormsDesigner.Services
57
public sealed class DefaultServiceContainer : ServiceContainer
59
public DefaultServiceContainer()
64
public DefaultServiceContainer(IServiceContainer parent)
69
#if WFDESIGN_LOG_SERVICE_REQUESTS
70
public override object GetService(Type serviceType)
72
object service = base.GetService(serviceType);
73
if (service == null) {
74
LoggingService.InfoFormatted("request missing service : {0} from Assembly {1} is not available.", serviceType, serviceType.Assembly.FullName);
76
LoggingService.DebugFormatted("get service : {0} from Assembly {1}.", serviceType, serviceType.Assembly.FullName);