1 #include "itemptywnd.h"
4 ItemPtyWnd::ItemPtyWnd(BaseObjectType* cobject, const Glib::RefPtr<Gnome::Glade::Xml>& refGlade):PropertyWnd(cobject,refGlade)
6 refGlade->get_widget("spin_caudal", spin_caudal);
7 refGlade->get_widget("txt_item_name",txt_item_name);
8 refGlade->get_widget("rd_btn_division", rd_btn_division);
9 refGlade->get_widget("rd_btn_union", rd_btn_union);
10 refGlade->get_widget("lb_type", lb_type);
11 refGlade->get_widget("lb_max_fluid", lb_max_fluid);
12 rd_btn_division->signal_clicked().connect(SigC::slot(*this,&ItemPtyWnd::on_rd_btn_division_clicked));
13 rd_btn_union->signal_clicked().connect(SigC::slot(*this,&ItemPtyWnd::on_rd_btn_union_clicked));
16 ItemPtyWnd::~ItemPtyWnd()
20 void ItemPtyWnd::on_btn_accept_clicked()
22 item->set_caudal( spin_caudal->get_value() );
23 item->set_name( txt_item_name->get_text() );
27 void ItemPtyWnd::on_btn_apply_clicked()
29 item->set_caudal( spin_caudal->get_value() );
30 item->set_name( txt_item_name->get_text() );
33 void ItemPtyWnd::on_btn_cancel_clicked()
38 void ItemPtyWnd::on_rd_btn_union_clicked()
40 item->connect_vec[0].type = IN;
41 item->connect_vec[1].type = IN;
42 item->connect_vec[2].type = OUT;
43 item->is_union = true;
46 void ItemPtyWnd::on_rd_btn_division_clicked()
48 item->connect_vec[0].type = OUT;
49 item->connect_vec[1].type = OUT;
50 item->connect_vec[2].type = IN;
51 item->is_union = false;