Coded cleanup
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
event EventHandler? BrowseButtonClicked;
|
||||
event EventHandler<string>? LaunchButtonClicked;
|
||||
event EventHandler<MaintainSermonFilerModel>? SaveButtonClicked;
|
||||
event EventHandler? CancelButtonClicked;
|
||||
event EventHandler<int>? CancelButtonClicked;
|
||||
|
||||
}
|
||||
}
|
||||
@@ -62,8 +62,6 @@ namespace MVPLearning.RecordKeeping.SermonFiler
|
||||
ButtonSave = new Button();
|
||||
ButtonCancel = new Button();
|
||||
LabelTitleWarning = new Label();
|
||||
button1 = new Button();
|
||||
button2 = new Button();
|
||||
ActionPanel.SuspendLayout();
|
||||
SuspendLayout();
|
||||
//
|
||||
@@ -365,33 +363,11 @@ namespace MVPLearning.RecordKeeping.SermonFiler
|
||||
LabelTitleWarning.Text = "Title cannont be blank";
|
||||
LabelTitleWarning.Visible = false;
|
||||
//
|
||||
// button1
|
||||
//
|
||||
button1.Location = new Point(517, 142);
|
||||
button1.Name = "button1";
|
||||
button1.Size = new Size(75, 23);
|
||||
button1.TabIndex = 26;
|
||||
button1.Text = "Rebind";
|
||||
button1.UseVisualStyleBackColor = true;
|
||||
button1.Click += button1_Click;
|
||||
//
|
||||
// button2
|
||||
//
|
||||
button2.Location = new Point(517, 177);
|
||||
button2.Name = "button2";
|
||||
button2.Size = new Size(75, 23);
|
||||
button2.TabIndex = 27;
|
||||
button2.Text = "button2";
|
||||
button2.UseVisualStyleBackColor = true;
|
||||
button2.Click += button2_Click;
|
||||
//
|
||||
// MaintainSermonFilerView
|
||||
//
|
||||
AutoScaleDimensions = new SizeF(7F, 15F);
|
||||
AutoScaleMode = AutoScaleMode.Font;
|
||||
ClientSize = new Size(800, 450);
|
||||
Controls.Add(button2);
|
||||
Controls.Add(button1);
|
||||
Controls.Add(LabelTitleWarning);
|
||||
Controls.Add(ButtonCancel);
|
||||
Controls.Add(ButtonSave);
|
||||
@@ -459,7 +435,5 @@ namespace MVPLearning.RecordKeeping.SermonFiler
|
||||
private Button ButtonSave;
|
||||
private Button ButtonCancel;
|
||||
private Label LabelTitleWarning;
|
||||
private Button button1;
|
||||
private Button button2;
|
||||
}
|
||||
}
|
||||
@@ -126,7 +126,7 @@ namespace MVPLearning.RecordKeeping.SermonFiler
|
||||
public event EventHandler? BrowseButtonClicked;
|
||||
public event EventHandler<string>? LaunchButtonClicked;
|
||||
public event EventHandler<MaintainSermonFilerModel>? SaveButtonClicked;
|
||||
public event EventHandler? CancelButtonClicked;
|
||||
public event EventHandler<int>? CancelButtonClicked;
|
||||
|
||||
private void AddButton_Click(object sender, EventArgs _) { if (CheckForChangedData()) { AddButtonClicked?.Invoke(sender, EventArgs.Empty); } }
|
||||
private void DeleteButton_Click(object sender, EventArgs _) { DeleteButtonClicked?.Invoke(sender, _model.Seid); }
|
||||
@@ -137,7 +137,7 @@ namespace MVPLearning.RecordKeeping.SermonFiler
|
||||
private void BrowseButton_Click(object sender, EventArgs _) { if (CheckForChangedData()) { BrowseButtonClicked?.Invoke(sender, EventArgs.Empty); } }
|
||||
private void LaunchButton_Click(object sender, EventArgs _) { LaunchButtonClicked?.Invoke(sender, _model.Filename); }
|
||||
private void SaveButton_Click(object sender, EventArgs _) { SaveButtonClicked?.Invoke(sender, _model); }
|
||||
private void CancelButton_Click(object sender, EventArgs _) { if (_loadedModel != null) { LoadData(_loadedModel); } }
|
||||
private void CancelButton_Click(object sender, EventArgs _) { CancelButtonClicked?.Invoke(sender, _model.Seid); }
|
||||
|
||||
|
||||
|
||||
@@ -154,14 +154,6 @@ namespace MVPLearning.RecordKeeping.SermonFiler
|
||||
return true;
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
{
|
||||
BindControls();
|
||||
}
|
||||
|
||||
private void button2_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.Refresh();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user