Beispiel #1
0
 /// <summary>
 /// 构造函数
 /// </summary>
 /// <param name="allTagNames">所有标签</param>
 public AddFileDialog(IEnumerable <string> allTagNames)
 {
     InitializeComponent();
     DataContext = this;
     foreach (string tagName in allTagNames)
     {
         FileTags.Add(new SelectableFileTag(tagName));
     }
 }
Beispiel #2
0
 public EditFileDialog(FileInfoForEdit fileInfo, IEnumerable <string> allTagName)
 {
     InitializeComponent();
     FileInfo    = fileInfo;
     DataContext = this;
     //fill FileTag Collection
     foreach (string tagName in allTagName)
     {
         FileTags.Add(new SelectableFileTag(
                          tagName, fileInfo.TagNames.Contains(tagName)));
     }
 }