From 1de93e8dd01fe77711c1dd33fe295cffdfe988bd Mon Sep 17 00:00:00 2001 From: Lynnesbian Date: Tue, 1 Sep 2020 17:12:17 +1000 Subject: [PATCH] replaced outdated 'destroy's with 'dispose' --- MainWindow.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/MainWindow.cs b/MainWindow.cs index 318f4c8..8454779 100755 --- a/MainWindow.cs +++ b/MainWindow.cs @@ -64,11 +64,9 @@ namespace Buypeeb { ed.ContentArea.PackStart(edEntry, true, true, 10); edEntry.Show(); - // TODO: pressing enter should submit the form - ResponseType accepted = (ResponseType)ed.Run(); string response = edEntry.Text; - ed.Destroy(); + ed.Dispose(); return (accepted == ResponseType.Ok, response); } @@ -99,7 +97,7 @@ namespace Buypeeb { private void ButtonQuitClicked(object sender, EventArgs a) { MessageDialog md = new MessageDialog(null, DialogFlags.DestroyWithParent, MessageType.Question, ButtonsType.OkCancel, "Are you sure you want to quit?"); ResponseType response = (ResponseType)md.Run(); - md.Destroy(); + md.Dispose(); if (response == ResponseType.Ok) { Application.Quit(); }