replaced outdated 'destroy's with 'dispose'
This commit is contained in:
parent
88f4adc02d
commit
1de93e8dd0
1 changed files with 2 additions and 4 deletions
|
@ -64,11 +64,9 @@ namespace Buypeeb {
|
||||||
ed.ContentArea.PackStart(edEntry, true, true, 10);
|
ed.ContentArea.PackStart(edEntry, true, true, 10);
|
||||||
edEntry.Show();
|
edEntry.Show();
|
||||||
|
|
||||||
// TODO: pressing enter should submit the form
|
|
||||||
|
|
||||||
ResponseType accepted = (ResponseType)ed.Run();
|
ResponseType accepted = (ResponseType)ed.Run();
|
||||||
string response = edEntry.Text;
|
string response = edEntry.Text;
|
||||||
ed.Destroy();
|
ed.Dispose();
|
||||||
return (accepted == ResponseType.Ok, response);
|
return (accepted == ResponseType.Ok, response);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -99,7 +97,7 @@ namespace Buypeeb {
|
||||||
private void ButtonQuitClicked(object sender, EventArgs a) {
|
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?");
|
MessageDialog md = new MessageDialog(null, DialogFlags.DestroyWithParent, MessageType.Question, ButtonsType.OkCancel, "Are you sure you want to quit?");
|
||||||
ResponseType response = (ResponseType)md.Run();
|
ResponseType response = (ResponseType)md.Run();
|
||||||
md.Destroy();
|
md.Dispose();
|
||||||
if (response == ResponseType.Ok) {
|
if (response == ResponseType.Ok) {
|
||||||
Application.Quit();
|
Application.Quit();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue