src/graph_gui.cpp
changeset 6596 0c6bff37a6e8
parent 6574 e1d1a12faaf7
child 6676 30aea9ac89bc
equal deleted inserted replaced
6595:6732a818a599 6596:0c6bff37a6e8
   797 
   797 
   798 	/* Resize the window to fit the cargo types */
   798 	/* Resize the window to fit the cargo types */
   799 	ResizeWindow(w, 0, num_active * 8);
   799 	ResizeWindow(w, 0, num_active * 8);
   800 
   800 
   801 	/* Add widgets for each cargo type */
   801 	/* Add widgets for each cargo type */
   802 	w->widget_count = 3 + num_active;
   802 	w->widget_count += num_active;
   803 	w->widget = ReallocT(w->widget, w->widget_count);
   803 	w->widget = ReallocT(w->widget, w->widget_count + 1);
       
   804 	w->widget[w->widget_count].type = WWT_LAST;
   804 
   805 
   805 	/* Set the properties of each widget */
   806 	/* Set the properties of each widget */
   806 	for (uint i = 0; i != num_active; i++) {
   807 	for (uint i = 0; i != num_active; i++) {
   807 		Widget *wi = &w->widget[3 + i];
   808 		Widget *wi = &w->widget[3 + i];
   808 		wi->type     = WWT_PANEL;
   809 		wi->type     = WWT_PANEL;