/// <summary>
		/// Gets the editor to use to edit <see cref="HeaderInfo"/>.
		/// </summary>
		/// <param name="p_hdrHeader">The header to edit.</param>
		/// <param name="p_lstModFiles">The list of files in the mod to which the <see cref="XmlScript"/>
		/// being edited belongs.</param>
		/// <returns>The editor to use to edit <see cref="HeaderInfo"/>. <c>null</c> is returned if the
		/// current <see cref="XmlScript"/> does not support editing the <see cref="HeaderInfo"/>.</returns>
		public virtual NodeEditor GetHeaderEditor(HeaderInfo p_hdrHeader, IList<VirtualFileSystemItem> p_lstModFiles)
		{
			HeaderEditorVM vmlHeaderEditor = new HeaderEditorVM(p_hdrHeader, p_lstModFiles, HeaderProperties.Title);
			return new HeaderEditor(vmlHeaderEditor);
		}
Пример #2
0
		public HeaderEditor(HeaderEditorVM p_vmlViewModel)
		{
			InitializeComponent();
			ViewModel = p_vmlViewModel;
		}
		/// <summary>
		/// Gets the editor to use to edit <see cref="HeaderInfo"/>.
		/// </summary>
		/// <param name="p_hdrHeader">The header to edit.</param>
		/// <param name="p_lstModFiles">The list of files in the mod to which the <see cref="XmlScript"/>
		/// being edited belongs.</param>
		/// <returns>The editor to use to edit <see cref="HeaderInfo"/>. <c>null</c> is returned if the
		/// current <see cref="XmlScript"/> does not support editing the <see cref="HeaderInfo"/>.</returns>
		public virtual NodeEditor GetHeaderEditor(HeaderInfo p_hdrHeader, IList<VirtualFileSystemItem> p_lstModFiles)
		{
			HeaderEditorVM vmlHeaderEditor = new HeaderEditorVM(p_hdrHeader, p_lstModFiles, HeaderProperties.Title | HeaderProperties.TextColour | HeaderProperties.TextPosition | HeaderProperties.Image | HeaderProperties.Height);
			return new HeaderEditor(vmlHeaderEditor);
		}
 public HeaderEditor(HeaderEditorVM p_vmlViewModel)
 {
     InitializeComponent();
     ViewModel = p_vmlViewModel;
 }