- if (connect_vec[0].type != UNDEF && connect_vec[1].type != UNDEF)
- return ( is_connected = (connect_vec[0].type == connect_vec[1].type) );
- else return false;
+ if (connect_vec[0].type != UNDEF && connect_vec[1].type != UNDEF) {
+ aux = connect_vec[0].type;
+ connect_vec[0].type = connect_vec[1].type;
+ connect_vec[1].type = aux;
+ connect_vec[0].id_dest = _item0->get_id();
+ connect_vec[1].id_dest = _item1->get_id();
+ return ( is_connected = (connect_vec[0].type != connect_vec[1].type) );
+ }
+ else return is_connected;