diff -r 05b0e8d057a6 -r 9c061834b33b gui/algobox.cc --- a/gui/algobox.cc Fri Jan 06 14:44:04 2006 +0000 +++ b/gui/algobox.cc Fri Jan 06 16:07:08 2006 +0000 @@ -73,11 +73,13 @@ } for(int i=0;i<(int)nodemapcbts.size();i++) { - update_cbt(nml, *(nodemapcbts[i])); + (nodemapcbts[i])->update_list(nml); + //update_cbt(nml, *(nodemapcbts[i])); } for(int i=0;i<(int)edgemapcbts.size();i++) { - update_cbt(eml, *(edgemapcbts[i])); + (edgemapcbts[i])->update_list(eml); + //update_cbt(eml, *(edgemapcbts[i])); } } @@ -106,7 +108,7 @@ { pack_start(*(new Gtk::HSeparator())); - label=new Gtk::Label("Specific part for each algorithm."); + Gtk::Label * label=new Gtk::Label("Specific part for each algorithm."); pack_start(*label); pack_start(*(new Gtk::HSeparator())); @@ -118,17 +120,15 @@ nodemapcbts.resize(NODE_INPUT_NUM); for(int i=0;i<(int)nodemapcbts.size();i++) { - Gtk::HBox * hbox=new Gtk::HBox(); + std::vector empty_vector; std::ostringstream o; o << "NodeInput " << i+1 << ":"; - label=new Gtk::Label(o.str()); - nodemapcbts[i]=new Gtk::ComboBoxText(); + nodemapcbts[i]=new MapSelector(empty_vector,"",o.str(),false, false); + nodemapcbts[i]->signal_newmapwin_needed().connect(sigc::mem_fun(*this, &AlgoBox::emit_new_map_signal)); - hbox->pack_start(*label); - hbox->pack_start(*(nodemapcbts[i])); - pack_start(*hbox); + pack_start(*(nodemapcbts[i])); } pack_start(*(new Gtk::HSeparator())); @@ -136,17 +136,15 @@ edgemapcbts.resize(EDGE_INPUT_NUM); for(int i=0;i<(int)edgemapcbts.size();i++) { - Gtk::HBox * hbox=new Gtk::HBox(); + std::vector empty_vector; std::ostringstream o; o << "EdgeInput " << i+1 << ":"; - label=new Gtk::Label(o.str()); - edgemapcbts[i]=new Gtk::ComboBoxText(); + edgemapcbts[i]=new MapSelector(empty_vector,"",o.str(),true, false); + edgemapcbts[i]->signal_newmapwin_needed().connect(sigc::mem_fun(*this, &AlgoBox::emit_new_map_signal)); - hbox->pack_start(*label); - hbox->pack_start(*(edgemapcbts[i])); - pack_start(*hbox); + pack_start(*(edgemapcbts[i])); } pack_start(*(new Gtk::HSeparator())); @@ -170,3 +168,8 @@ update_maplist(NULL); } } + +void AlgoBox::emit_new_map_signal(bool itisedge) +{ + signal_newmapwin_need.emit(tabcbt.get_active_text(), itisedge); +}