76 lines
2.4 KiB
C#
76 lines
2.4 KiB
C#
using System.Collections.Generic;
|
|
using System.Configuration;
|
|
using JD.Adobe.Service.Implementation;
|
|
using JD.Nas.Service;
|
|
using JD.Shotgun.Service;
|
|
using Orbit.Module;
|
|
using Plume.ErrorList;
|
|
using Plume.Interfaces.Services;
|
|
using Plume.Interfaces.WPF.Actions;
|
|
using Plume.Interfaces.WPF.Menu;
|
|
using Plume.Interfaces.WPF.Modules;
|
|
using Plume.Output;
|
|
using Plume.Perforce;
|
|
using Plume.Perforce.Service.Implementation;
|
|
|
|
namespace Orbit.Photoshop
|
|
{
|
|
/// <summary>
|
|
/// Interaction logic for App.xaml
|
|
/// </summary>
|
|
public partial class App
|
|
{
|
|
public App()
|
|
{
|
|
Title = "Orbit - Photoshop";
|
|
}
|
|
|
|
public override bool HasDocumentWorkspace => false;
|
|
|
|
protected override IEnumerable<WpfModuleInfo> SetupModules()
|
|
{
|
|
yield return new WpfModuleInfo(new ErrorListModule());
|
|
yield return new WpfModuleInfo(new OutputModule());
|
|
yield return new WpfModuleInfo(new PerforceModule(), new PerforceModuleSetup
|
|
{
|
|
DefaultPerforceHost = ConfigurationManager.AppSettings["DefaultPerforceHost"]
|
|
});
|
|
|
|
yield return new WpfModuleInfo(new OrbitModule(), new OrbitModuleSetup
|
|
{
|
|
ShuttleNasPath = ConfigurationManager.AppSettings["ShuttleNasPath"],
|
|
NasRootPath = ConfigurationManager.AppSettings["NasRootPath"]
|
|
});
|
|
}
|
|
|
|
protected override IEnumerable<IService> SetupServices()
|
|
{
|
|
yield return new PerforceService();
|
|
|
|
var photoshopServiceLogger = LoggerManager.GetOrCreateLogger(nameof(PhotoshopService));
|
|
yield return new PhotoshopService(photoshopServiceLogger);
|
|
|
|
yield return new NasService();
|
|
|
|
yield return new ShotgunService();
|
|
}
|
|
|
|
protected override void OnMenuInitialization()
|
|
{
|
|
base.OnMenuInitialization();
|
|
|
|
MenuManager.GetMenuItem(MenuPath.FileMenu).Items.Clear();
|
|
MenuManager.AddMenuItem(MenuPath.FileMenu, ActionManager.Get(StandardAction.ShowSettingsDialog));
|
|
MenuManager.AddSeparator(MenuPath.FileMenu);
|
|
MenuManager.AddMenuItem(MenuPath.FileMenu, ActionManager.Get(StandardAction.Exit));
|
|
|
|
MenuManager.RemoveMenu(MenuPath.EditMenu);
|
|
}
|
|
|
|
protected override void OnApplicationReady()
|
|
{
|
|
base.OnApplicationReady();
|
|
ModuleManager.Get<OrbitModule>().OnApplicationReady();
|
|
}
|
|
}
|
|
}
|