src/train_gui.cpp
branchcpp_gui
changeset 6247 67e881450cf3
parent 6246 2a4c2c4d66f0
child 6250 5135b200b376
--- a/src/train_gui.cpp	Tue Feb 13 22:09:37 2007 +0000
+++ b/src/train_gui.cpp	Tue Feb 13 22:17:48 2007 +0000
@@ -152,14 +152,14 @@
 		w->SetWidgetDisabledState(13, !is_localplayer);
 
 		/* Disable cargo refit button, until we know we can enable it below. */
-		DisableWindowWidget(w, 12);
+		w->DisableWidget(12);
 
 		if (is_localplayer) {
 			/* See if any vehicle can be refitted */
 			for (u = v; u != NULL; u = u->next) {
 				if (EngInfo(u->engine_type)->refit_mask != 0 ||
 						(RailVehInfo(v->engine_type)->railveh_type != RAILVEH_WAGON && v->cargo_cap != 0)) {
-					EnableWindowWidget(w, 12);
+					w->EnableWidget(12);
 					/* We have a refittable carriage, bail out */
 					break;
 				}
@@ -405,7 +405,7 @@
 
 	SetVScrollCount(w, num);
 
-	DisableWindowWidget(w, det_tab + 9);
+	w->DisableWidget(det_tab + 9);
 	w->SetWidgetDisabledState(2, v->owner != _local_player);
 
 	/* disable service-scroller when interval is set to disabled */
@@ -540,11 +540,11 @@
 		case 10: // Information
 		case 11: // Capacities
 		case 12: // Total cargo
-			EnableWindowWidget(w,  9);
-			EnableWindowWidget(w, 10);
-			EnableWindowWidget(w, 11);
-			EnableWindowWidget(w, 12);
-			EnableWindowWidget(w, e->we.click.widget);
+			w->EnableWidget( 9);
+			w->EnableWidget(10);
+			w->EnableWidget(11);
+			w->EnableWidget(12);
+			w->EnableWidget(e->we.click.widget);
 			WP(w,traindetails_d).tab = e->we.click.widget - 9;
 			w->SetDirty();
 			break;