pragma License(Unrestricted); --with Gtk; use Gtk; with Gtk.Window; use Gtk.Window; with Gtk.Dialog; use Gtk.Dialog; with Gtk.Message_Dialog; use Gtk.Message_Dialog; with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; package body Message_Box is procedure M_Box(Title : String; Text : String) is MessageBox : Gtk_Message_Dialog; begin MessageBox := Gtk_Message_Dialog_New(null, 1, Message_Warning, Buttons_Close, Text); MessageBox.Set_Title(Title); if MessageBox.Run <= 0 then MessageBox.Destroy; end if; end M_Box; procedure M_Box(Title : UnBounded_String; Text : UnBounded_String) is begin M_Box(To_String(Title), To_String(Text)); end M_Box; procedure M_Box(Title : UnBounded_String; Text : String) is begin M_Box(To_String(Title), Text); end M_Box; procedure M_Box(Title : String; Text : UnBounded_String) is begin M_Box(Title, To_String(Text)); end M_Box; end Message_Box;