method rebuild (msg:(string,string) env) =
begin
(* Save the current selected choice. We will try to reset it. *)
let previous = self#selected in
(* Destroy the old combo box. *)
self#box#destroy () ; (* Essentiel! *)
(* Rebuild combo list. *)
let strList = (self#generator msg) in
let (combo, (_, column)) = GEdit.combo_box_text ~strings:strList () in
self#set_box combo ;
self#set_col column ;
self#set_choices strList ;
self#initialize_callbacks ; (* Re-initialize callbacks for the new box! *)
self#packing (self#box :> GObj.widget) ; (* repack self *)
(* Register the last master environment *)
self#set_env msg ;
(* Try to restore the previous selected value (or select the index 0) *)
let i = ((List.indexOf previous self#choices) |=> 0) in
(self#box#set_active i) ;
(* Propagate to its childs. *)
self#childs_rebuild () ;
()
end