diff -r 69a2910ec6f9 -r 10acb6a11a73 client/src/Iri.Modernisation.Controls/ViewModel/ProductionTimeLine/ProductionTimeLineVM.cs --- a/client/src/Iri.Modernisation.Controls/ViewModel/ProductionTimeLine/ProductionTimeLineVM.cs Mon Dec 14 11:25:01 2009 +0100 +++ b/client/src/Iri.Modernisation.Controls/ViewModel/ProductionTimeLine/ProductionTimeLineVM.cs Mon Dec 14 17:02:03 2009 +0100 @@ -64,7 +64,21 @@ OnPropertyChanged("SelectedVideoSequences"); } } - + public TimeSpan TotalBookDuration + { + get + { + TimeSpan temp = TimeSpan.Zero; + foreach (ObservableCollection Ocvs in _listVideoSequences) + { + foreach (VideoSequence Vs in Ocvs) + { + temp += Vs.Duration; + } + } + return temp; + } + } public VideoChapter[] Chapters { get @@ -97,6 +111,19 @@ } + private double _position; + public double Position + { + get + { + return _position; + } + set + { + _position = value; + OnPropertyChanged("Position"); + } + } private ObservableCollection[] _listSegmentIndex; public ObservableCollection[] ListIndex @@ -189,6 +216,7 @@ TimerOut = dur, Chapter = SelectedBookChapter }); + } } @@ -196,10 +224,12 @@ void DelVideoSequence_Executed(object sender, SLExtensions.Input.ExecutedEventArgs e) { SelectedVideoSequences.Remove(((CustomableVideoElementVM)e.Parameter).VideoSequence); + OnPropertyChanged("TotalBookDuration"); } void SelectedVideoSequences_CollectionChanged(object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) { + OnPropertyChanged("TotalBookDuration"); Commands.ProductionView.VideoRecordUpdated.Execute(); } @@ -220,5 +250,6 @@ SelectedChapterType = ((HeaderProductionEventArgs)e.Source).ChapterType ; IsIndexing = ((HeaderProductionEventArgs)e.Source).IsIndexPart; } + } }