I have displayTabPanel function and im applying it multiples times with different parameters like this :
var display = function () {
displayTabPanel(tab1, tab1_name, tab1_width, tab1_height, tab1_btn);
displayTabPanel(tab2, tab2_name, tab2_width, tab2_height, tab2_btn);
displayTabPanel(tab3, tab3_name, tab3_width, tab3_height, tab3_btn);
};
var displayTabPanel = function(tab, tab_name, tab_width, tab_height, tab_btn){
//...
};
i have at least 9 of those calls, and its realy ugly to put it this way ,
is there a better way to do this ?
If its just a readability thing you could do the following: