Example #1
0
        public PropertySynchronizer(EditID3v1Tag v1Tag, EditID3v2Tag v2Tag, string v1TagPropertyName, params string[] v2TagFrameIds)
        {
            this.v1Tag             = v1Tag;
            this.v2Tag             = v2Tag;
            this.v1TagPropertyName = v1TagPropertyName;
            this.v2TagFrameIds     = v2TagFrameIds;

            v1Tag.PropertyChanged   += V1Tag_PropertyChanged;
            v2Tag.CollectionChanged += V2Tag_CollectionChanged;

            foreach (EditTextFrame frame in v2Tag.GetTextFrames())
            {
                if (v2TagFrameIds.Contains(frame.FrameId))
                {
                    frame.PropertyChanged += Frame_PropertyChanged;
                }
            }

            SetValue();
        }
Example #2
0
 private IEnumerable <EditTextFrame> GetTextFrames()
 {
     return(v2Tag.GetTextFrames().Where(f => v2TagFrameIds.Contains(f.FrameId)));
 }