# HG changeset patch # User IBBoard # Date 1251485554 0 # Node ID 83c8945edac298d2c92888c759bea9fd79964271 # Parent 3a396783bfedcff7b908ed94af9dffa29bbc7078 Re #143: GTK "Army has been modified" dialog has no buttons * Button types can't be bitwise ORed so just use YesNo for now (Yes, No, Cancel dialog would be better) Also: * Make sure that we dispose of the dialog diff -r 3a396783bfed -r 83c8945edac2 FrmMainWindow.cs --- a/FrmMainWindow.cs Fri Aug 28 18:47:10 2009 +0000 +++ b/FrmMainWindow.cs Fri Aug 28 18:52:34 2009 +0000 @@ -807,8 +807,10 @@ if (CommandStack.IsDirty()) { - MessageDialog dia = new MessageDialog(this, DialogFlags.DestroyWithParent, MessageType.Question, ButtonsType.YesNo | ButtonsType.Cancel, "The army \""+WarFoundryCore.CurrentArmy.Name+"\" has been modified.\r\nSave changes before closing army?"); + MessageDialog dia = new MessageDialog(this, DialogFlags.DestroyWithParent, MessageType.Question, ButtonsType.YesNo, "The army \""+WarFoundryCore.CurrentArmy.Name+"\" has been modified.\r\nSave changes before closing army?"); ResponseType dr = (ResponseType)dia.Run(); + dia.Hide(); + dia.Dispose(); if (dr == ResponseType.Yes) { @@ -826,8 +828,6 @@ //Assume cancel or close with the X button canClose = false; } - - dia.Dispose(); } else {