private void AddImage(object sender, EventArgs e) { FileWindow senderWindow = (sender as FileWindow); if (!senderWindow.OK) { return; } _markdown.Image(AppPathInfo.BlogFilePath + senderWindow.FileName); }
private void SyntaxImage_Click(object sender, EventArgs e) { using FileWindow fileWindow = new FileWindow(); fileWindow.FormClosed += AddImage; fileWindow.ShowDialog(this); }