@@ -226,7 +226,7 @@ private void ModifyWindowSize()
226226 if ( SymbolsRowCount > 0 )
227227 {
228228 var desiredHeight = FontToBold ? Owner . TextFontDefaultBold . Height * RowsCount
229- : Owner . TextFontDefault . Height * RowsCount + SymbolWidth ;
229+ : ( Owner . TextFontDefault . Height * RowsCount ) + SymbolWidth ;
230230 var desiredWidth = ( SymbolsRowCount * SymbolWidth ) + ( SpacerRowCount * ( SymbolWidth / 2 ) ) + ( LocoRowCount * ( SymbolWidth * 2 ) ) ;
231231
232232 var newHeight = ( int ) MathHelper . Clamp ( desiredHeight , 80 , WindowHeightMax ) ;
@@ -406,8 +406,8 @@ public override void PrepareFrame(ElapsedTime elapsedTime, bool updateFull)
406406 // Updates power supply status
407407 else if ( isElectricDieselLocomotive &&
408408 ( PowerSupplyStatus != null && PowerSupplyStatus != Owner . Viewer . PlayerTrain . Cars [ CarPosition ] . GetStatus ( )
409- || BatteryStatus != null && BatteryStatus != Owner . Viewer . PlayerTrain . Cars [ CarPosition ] . GetStatus ( )
410- || CircuitBreakerState != null && CircuitBreakerState != ( trainCar as MSTSElectricLocomotive ) . ElectricPowerSupply . CircuitBreaker . State . ToString ( ) ) )
409+ || ( BatteryStatus != null && BatteryStatus != Owner . Viewer . PlayerTrain . Cars [ CarPosition ] . GetStatus ( ) )
410+ || ( CircuitBreakerState != null && CircuitBreakerState != ( trainCar as MSTSElectricLocomotive ) . ElectricPowerSupply . CircuitBreaker . State . ToString ( ) ) ) )
411411 {
412412 Layout ( ) ;
413413 UpdateWindowSize ( ) ;
@@ -549,8 +549,6 @@ void buttonHandBrake_Click(Control arg1, Point arg2)
549549 if ( ( Viewer . PlayerTrain . Cars [ CarPosition ] as MSTSWagon ) . GetTrainHandbrakeStatus ( ) )
550550 {
551551 Viewer . Simulator . Confirmer . Information ( Viewer . Catalog . GetString ( "Handbrake set" ) ) ;
552-
553-
554552 Texture = HandBrakeSet ;
555553 }
556554 else
@@ -849,7 +847,7 @@ public buttonToggleMU(int x, int y, int size, Viewer viewer, int carPosition)
849847 var multipleUnitsConfiguration = Viewer . PlayerLocomotive . GetMultipleUnitsConfiguration ( ) ;
850848 if ( Viewer . PlayerTrain . Cars [ CarPosition ] is MSTSDieselLocomotive && multipleUnitsConfiguration != null )
851849 {
852- Texture = Viewer . TrainCarOperationsWindow . ModifiedSetting || ( Viewer . PlayerTrain . Cars [ CarPosition ] as MSTSLocomotive ) . RemoteControlGroup == 0 && multipleUnitsConfiguration != "1" ? MUconnected : MUdisconnected ;
850+ Texture = Viewer . TrainCarOperationsWindow . ModifiedSetting || ( ( Viewer . PlayerTrain . Cars [ CarPosition ] as MSTSLocomotive ) . RemoteControlGroup == 0 && multipleUnitsConfiguration != "1" ) ? MUconnected : MUdisconnected ;
853851 }
854852 else
855853 {
0 commit comments