Exemplo n.º 1
0
        public static void UnregisterProvider(Type contentType)
        {
            var progId = ComExtensions.GetProgId(
                hostType: typeof(PrismTaskPanesHost),
                contentType: contentType);

            ComExtensions.Unregister(
                progId: progId);
        }
Exemplo n.º 2
0
        public TaskPanesFactory(int windowKey, ICTPFactory ctpFactory, IRegionManager hostRegionManager,
                                object taskPaneWindow, Type contentType)
        {
            progId = ComExtensions.GetProgId(
                hostType: typeof(PrismTaskPanesHost),
                contentType: contentType);

            if (Type.GetTypeFromProgID(progId) == default)
            {
                throw new HostNotRegisteredException();
            }

            this.windowKey         = windowKey;
            this.ctpFactory        = ctpFactory;
            this.hostRegionManager = hostRegionManager;
            this.taskPaneWindow    = taskPaneWindow;
        }