using System.Windows.Input; using JD.Inspector.Actions; using JD.Inspector.Plugin; using JD.Inspector.View; using JD.Inspector.ViewModel; using JD.Remoting.Services; using Plume.Icons; using Plume.Interfaces.Modules; using Plume.Interfaces.WPF.Actions; using Plume.Interfaces.WPF.Menu; using Plume.Interfaces.WPF.Modules; using Plume.Interfaces.WPF.ToolBar; using Plume.Interfaces.WPF.Window; using Plume.WPF.Commands; namespace JD.Inspector { public class InspectorModule : IWpfModule { private IModuleSetup _setup; /// public void Dispose() { //Nothing to dispose } /// public void Setup(IModuleSetup setup) { _setup = setup; } /// public void Initialize(IWpfModuleContext context) { InspectorPlugin plugin = new InspectorPlugin(); context.GetService().Register(plugin); IActionManager actionService = context.ActionManager; IWindowManager windowService = context.WindowManager; IToolBarManager toolbarService = context.ToolBarManager; IMenuManager menuService = context.MenuManager; InspectorView inspectorView = new InspectorView { DataContext = new InspectorViewModel(plugin, context.ServiceManager, context.NotificationManager) }; windowService.AddToolWindow("InspectorWindow", "Inspector", StandardIcon.Property, inspectorView, DockingSide.Right, new DoubleKeyGesture(ModifierKeys.Control, Key.V, Key.I)); actionService.Register(); toolbarService.AddButton("Inspector", actionService.Get()); menuService.AddSeparator("Engine"); menuService.AddMenuItem("Engine", actionService.Get()); } } }