public ProjectKeyframeOverview(FileTreeObject fileTreeObject, ProjectManager projectManager, FFmpegManager ffmpegManager, DefaultCodecHeaderManager defaultCodecHeaderManager, FullFileScanner fullFileScanner, Creator <SelectingKeyframe> selectingKeyframeCreator) { if (_activeInstance != null) { throw new Exception("It's not allowed to create multiple ProjectKeyframeOverview windows."); } _activeInstance = this; _fileTreeObject = fileTreeObject; _projectManager = projectManager; _ffmpegManager = ffmpegManager; _defaultCodecHeaderManager = defaultCodecHeaderManager; _fullFileScanner = fullFileScanner; _selectingKeyframeCreator = selectingKeyframeCreator; InitializeComponent(); ReportProgressComplete(); _resultRows = new List <ProjectKeyframeOverviewRow>(); resultsTree.DataSource = _resultRows; projectManager.ProjectChanged += new EventHandler <ProjectChangedEventArgs>(projectManager_ProjectChanged); defaultCodecHeaderManager.CodecHeaderChanged += new DefaultCodecHeaderManager.DefaultCodecHeaderChangeHandler(defaultCodecHeaderManager_CodecHeaderChanged); fullFileScanner.ScanNextCodecStreamOnInvalidation = true; fullFileScanner.ScanMoreThanOneFragment = false; fullFileScanner.ScanProgressChanged += new ProgressChangedEventHandler(fullFileScanner_ScanProgressChanged); fullFileScanner.ResultDetected += new FullFileScanner.ResultDetectedHandler(fullFileScanner_ResultDetected); fullFileScanner.ScanCompleted += new FullFileScanner.ScanCompleteHandler(fullFileScanner_ScanCompleted); fullFileScanner.ScanNumCodecStreams = 1; // Limit to only 1 codecstream, otherwise the scan will take to long }
/// <summary> /// Creates a new selection. /// </summary> /// <param name="fileTreeObject">the tree for the selection</param> /// <param name="rowSelectionType">make the selection unique and in GUI order</param> public Selection(FileTreeObject fileTreeObject, RowSelectionType rowSelectionType) { _fileTreeObject = fileTreeObject; _rowSelectionType = rowSelectionType; }