public SettingsDialog(MainForm owner) { if (owner == null) { throw new ArgumentNullException("owner"); } InitializeComponent(); this.mOwner = owner; this.mActualVisSettings = new VisualSettings(); this.mPreviewVisSettings = new VisualSettings(); this.mPreviewVisSettings.FloatSettingChanged += new EventHandler<VisualSettings.FloatSettingEventArgs>( previewFloatSettingChanged); this.mPreviewVisSettings.ColorSettingChanged += new EventHandler<VisualSettings.ColorSettingEventArgs>( previewColorSettingChanged); this.mPreviewVisSettings.FontSettingChanged += new EventHandler<VisualSettings.FontSettingEventArgs>( previewFontSettingChanged); this.mPreviewVisSettings.SetApplyFloatChangesImmediately(false); this.mPreviewVisSettings.SetApplyColorChangesImmediately(true); this.mPreviewVisSettings.SetApplyFontChangesImmediately(false); this.graphVisualPropGrid.SelectedObject = this.mPreviewVisSettings; }
private void previewFontSettingChanged(object sender, VisualSettings.FontSettingEventArgs e) { this.applyBTN.Enabled = true; this.bVisualFontSettingsDirty = true; if (this.previewFontChangesCHK.Checked) { this.mOwner.RefreshJazzGraphs(true); } }
private void previewColorSettingChanged(object sender, VisualSettings.ColorSettingEventArgs e) { this.applyBTN.Enabled = true; this.bVisualColorSettingsDirty = true; if (this.previewColorChangesCHK.Checked) { this.mOwner.InvalidateJazzGraphs(); } }