public MainSplitContainer(CoreLib core, Options options, CoreOptions coreOptions, MainForm mainForm) { m_mainForm = mainForm; m_options = options; m_core = core; m_coreOptions = coreOptions; m_resultsListView = new ResultsListView(m_core, m_options, m_coreOptions, this); m_resultsPreviewContainer = new ResultsPreviewContainer(m_core, m_options, m_coreOptions, this); //m_resultsListView.UpdateResults(); m_thumbnailGroupTable = new ThumbnailGroupTable(m_core, m_options, this); m_thumbnailPreview = new ThumbnailPreview(m_core, m_options, this); m_thumbnailPreview.ContextMenuStrip = new ThumbnailPreviewContextMenu(m_core, m_options, m_thumbnailPreview, m_thumbnailGroupTable); m_thumbnailGroupTable.OnCurrentThumbnailChanged += m_thumbnailPreview.SetThumbnail; //m_thumbnailGroupTable.UpdateGroups(); InitializeComponents(); // —в¤зываем, чтобы при вызове событи¤ OnViewModeChange вызывалась функци¤ SetViewMode m_options.resultsOptions.OnViewModeChange += new ResultsOptions.ViewModeChangeHandler(SetViewMode); SplitterMoved += new SplitterEventHandler(OnSplitterPositionChanged); Resize += new EventHandler(OnSizeChanged); }
public ThumbnailPreviewContextMenu(CoreLib core, Options options, ThumbnailPreview thumbnailPreview, ThumbnailGroupTable thumbnailGroupTable) { m_core = core; m_options = options; m_thumbnailPreview = thumbnailPreview; m_thumbnailGroupTable = thumbnailGroupTable; InitializeComponents(); UpdateStrings(); Resources.Strings.OnCurrentChange += new Resources.Strings.CurrentChangeHandler(UpdateStrings); Opening += new CancelEventHandler(OnOpening); }