JD2022-TU1/main/tools/apps/DanceEditor/Addins/DanceEditor.addin.cs

225 lines
11 KiB
C#

using System;
using System.Xml.Linq;
using JD.TeaBoxAddinSystem.Addins;
public class DanceEditor_Addin : IXmlAddin
{
public string FileName => "DanceEditor.addin";
public XElement RootElement { get; } =
new XElement("TeaBox",
new XElement("Addin",
new XAttribute("id", "DanceEditor"),
new XAttribute("author", "Ubisoft"),
new XAttribute("category", "General"),
new XAttribute("name", "DanceEditor"),
new XAttribute("description", "Allows to edit dance tapes."),
new XElement("Files",
new XElement("Import",
new XAttribute("assembly", "DanceEditor.exe"),
new XElement("Import",
new XAttribute("resource", $"{typeof(DanceEditor.Properties.Resources).FullName}")
)
)
),
new XElement("Dependencies",
new XElement("Addin",
new XAttribute("id", "JD.Application")
),
new XElement("Addin",
new XAttribute("id", "TeaBox.Application")
),
new XElement("Addin",
new XAttribute("id", "Timeline")
)
),
// TreeViewToolbar
new XElement("Extension",
new XAttribute("path", "Application/TreeViewToolbar"),
new XElement("Actions",
new XAttribute("id", "TrackTreeView"),
new XAttribute("guid", "6DF581C9-6949-49F2-9B99-83F9C9DCDA5B"),
new XElement("Action",
new XAttribute("id", "DanceEditor.SelectNumberPlayersActionHandler"),
new XAttribute("description", "Select the number of players in current tape"),
new XAttribute("icon", "Icon_16x16_Player"),
new XAttribute("defaultHandler", $"{typeof(DanceEditor.Source.Actions.SelectNumberPlayersActionHandler).FullName}")
)
)
),
// ToolBars
new XElement("Extension",
new XAttribute("path", "Application/ToolBars"),
new XElement("Actions",
new XAttribute("id", "DanceEditor"),
new XAttribute("guid", "412E2170-F628-42D5-A2DB-424C6CBC6D3E"),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.TogglePlay")
),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.PreviousFrame")
),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.NextFrame")
),
new XElement("Actions",
new XAttribute("id", "MarkCheckpoint"),
new XAttribute("default_action", "EditorActions.MarkCheckpoint"),
new XAttribute("showIconAndText", "False"),
new XAttribute("icon", "Icons_30x30_Checkpoint"),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.MarkCheckpoint")
),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.GoToCheckpoint")
),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.ClearCheckpoint")
),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.Rewind")
)
),
new XElement("Separator"),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.SnapUnitDropdown")
),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.ScrollingModeDropdown")
),
new XElement("ActionReference",
new XAttribute("id", "EditorActions.ToggleLoop")
)
)
),
// DocumentBindings
new XElement("Extension",
new XAttribute("path", "Application/DocumentBindings"),
new XElement("DocumentBinding",
new XAttribute("id", "DanceTape"),
new XAttribute("name", "DanceTape"),
new XAttribute("icon", "Icon_16x16_DanceEditor"),
new XAttribute("class", "JD.Timeline.Dance.DanceDocumentBinding"),
new XElement("FileFilter",
new XAttribute("name", "Dance tape files"),
new XAttribute("extensions", "*.dtape;")
)
),
new XElement("DocumentBinding",
new XAttribute("id", "SignatureTape"),
new XAttribute("name", "SignatureTape"),
new XAttribute("icon", "Icon_16x16_TRec"),
new XAttribute("class", "JD.Timeline.MashupSignatureDocumentBinding"),
new XElement("FileFilter",
new XAttribute("name", "Mash up signature tape files"),
new XAttribute("extensions", "*.stape;")
)
),
new XElement("DocumentBinding",
new XAttribute("id", "VideoTape"),
new XAttribute("name", "VideoTape"),
new XAttribute("icon", "Icon_16x16_TRec"),
new XAttribute("class", "JD.Timeline.MashupVideoDocumentBinding"),
new XElement("FileFilter",
new XAttribute("name", "Mash up video tape files"),
new XAttribute("extensions", "*.btape;")
)
)
),
// ContextMenu
new XElement("ExtensionPoint",
new XAttribute("path", "Application/ClipView/ContextMenu"),
new XElement("ExtensionNodeSet",
new XAttribute("name", "Actions")
)
),
// ContextMenu
new XElement("Extension",
new XAttribute("path", "Application/ClipView/ContextMenu"),
new XElement("Action",
new XAttribute("id", "DanceEditorActions.AddClip"),
new XAttribute("type", "Array"),
new XAttribute("description", "Adds all the available clips as a separate action"),
new XAttribute("defaultHandler", $"{typeof(DanceEditor.Source.Actions.AddNewClipActionHandler).FullName}")
),
new XElement("ActionReference",
new XAttribute("id", "ActivateClips")
),
new XElement("ActionReference",
new XAttribute("id", "ToggleLabelsSniping")
),
new XElement("ActionReference",
new XAttribute("id", "SnipeClips")
),
new XElement("ActionReference",
new XAttribute("id", "ValidateRecordings")
)
),
// TreeViewToolbar
new XElement("ExtensionPoint",
new XAttribute("path", "Application/TreeViewToolbar"),
new XElement("ExtensionNodeSet",
new XAttribute("name", "ActionBaseSet")
)
),
// Pads
new XElement("Extension",
new XAttribute("path", "Application/Pads"),
new XElement("Pad",
new XAttribute("id", "Pleo"),
new XAttribute("category", "Main"),
new XAttribute("title", "Video player"),
new XAttribute("shortcut", "Ctrl+W, V"),
new XAttribute("icon", "Icon_16x16_video"),
new XAttribute("guid", "51D1D7DD-FB18-4B10-9F1F-8C31BA012186"),
new XAttribute("type", $"{typeof(JD.Timeline.View.VideoView.TapeVideoPad).FullName}")
),
new XElement("Pad",
new XAttribute("id", "MoveReference"),
new XAttribute("category", "Main"),
new XAttribute("title", "Move Reference"),
new XAttribute("shortcut", "Ctrl+W, V"),
new XAttribute("icon", "Icon_16x16_video"),
new XAttribute("guid", "72B2527C-63D7-468A-A5EF-B69CCFA1F5E1"),
new XAttribute("type", $"{typeof(JD.Timeline.View.Pads.MoveReferenceVideoPad).FullName}")
),
new XElement("Pad",
new XAttribute("id", "MovesLibrary"),
new XAttribute("category", "Main"),
new XAttribute("title", "Moves Library"),
new XAttribute("shortcut", "Ctrl+W, M"),
new XAttribute("icon", "Icon_24x24_move"),
new XAttribute("guid", "4E49126D-54B7-4A0C-9D4D-47FC2F5E6F2F"),
new XAttribute("type", $"{typeof(JD.Timeline.View.Pads.MovesPad).FullName}")
),
new XElement("Pad",
new XAttribute("id", "PictosLibrary"),
new XAttribute("category", "Main"),
new XAttribute("title", "Pictos Library"),
new XAttribute("shortcut", "Ctrl+W, P"),
new XAttribute("icon", "Icon_24x24_picto"),
new XAttribute("guid", "B9473705-30F8-48EA-9878-FA5F436F6FF4"),
new XAttribute("type", $"{typeof(JD.Timeline.View.Pads.PictosPad).FullName}")
),
new XElement("Pad",
new XAttribute("id", "PictosScrolling"),
new XAttribute("category", "Main"),
new XAttribute("title", "Pictos scrolling"),
new XAttribute("icon", "Icon_24x24_picto"),
new XAttribute("guid", "CB0E8E33-6F97-4CEC-B182-6682D9506264"),
new XAttribute("type", $"{typeof(JD.Timeline.Dance.PictogramScrollingPad).FullName}")
)
)
)
)
;
}