public ScrollingCaptureForm(ScrollingCaptureOptions options, bool forceSelection = false) { Options = options; InitializeComponent(); Icon = ShareXResources.Icon; cbScrollMethod.Items.AddRange(Helpers.GetEnumDescriptions<ScrollingCaptureScrollMethod>()); cbScrollMethod.SelectedIndex = (int)Options.ScrollMethod; cbScrollTopMethodBeforeCapture.Items.AddRange(Helpers.GetEnumDescriptions<ScrollingCaptureScrollTopMethod>()); cbScrollTopMethodBeforeCapture.SelectedIndex = (int)Options.ScrollTopMethodBeforeCapture; nudStartDelay.SetValue(Options.StartDelay); nudScrollDelay.SetValue(Options.ScrollDelay); nudMaximumScrollCount.SetValue(Options.MaximumScrollCount); cbStartSelectionAutomatically.Checked = Options.StartSelectionAutomatically; cbStartCaptureAutomatically.Checked = Options.StartCaptureAutomatically; cbAutoDetectScrollEnd.Checked = Options.AutoDetectScrollEnd; cbRemoveDuplicates.Checked = Options.RemoveDuplicates; cbAutoCombine.Checked = Options.AfterCaptureAutomaticallyCombine; chkAutoUpload.Checked = Options.AutoUpload; if (forceSelection || Options.StartSelectionAutomatically) { if (Options.StartCaptureAutomatically) { WindowState = FormWindowState.Minimized; } SelectHandle(); } }
public ScrollingCaptureForm(ScrollingCaptureOptions options, RegionCaptureOptions regionCaptureOptions, bool forceSelection = false) { Options = options; RegionCaptureOptions = regionCaptureOptions; InitializeComponent(); ShareXResources.ApplyTheme(this); cbScrollMethod.Items.AddRange(Helpers.GetLocalizedEnumDescriptions <ScrollingCaptureScrollMethod>()); cbScrollMethod.SelectedIndex = (int)Options.ScrollMethod; cbScrollTopMethodBeforeCapture.Items.AddRange(Helpers.GetLocalizedEnumDescriptions <ScrollingCaptureScrollTopMethod>()); cbScrollTopMethodBeforeCapture.SelectedIndex = (int)Options.ScrollTopMethodBeforeCapture; nudStartDelay.SetValue(Options.StartDelay); nudScrollDelay.SetValue(Options.ScrollDelay); nudMaximumScrollCount.SetValue(Options.MaximumScrollCount); cbStartSelectionAutomatically.Checked = Options.StartSelectionAutomatically; cbStartCaptureAutomatically.Checked = Options.StartCaptureAutomatically; cbAutoDetectScrollEnd.Checked = Options.AutoDetectScrollEnd; cbRemoveDuplicates.Checked = Options.RemoveDuplicates; cbAutoCombine.Checked = Options.AfterCaptureAutomaticallyCombine; chkAutoUpload.Checked = Options.AutoUpload; if (forceSelection || Options.StartSelectionAutomatically) { if (Options.StartCaptureAutomatically) { WindowState = FormWindowState.Minimized; } SelectHandle(); } }
public ScrollingCaptureForm(ScrollingCaptureOptions options) { Options = options; InitializeComponent(); nudScrollDelay.Value = Options.ScrollDelay; nudMaximumScrollCount.Value = Options.MaximumScrollCount; }