From 24deec2a7bd3473a6ece7c3aa7a7fd4e8bce6878 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 25 Jan 2015 18:18:31 +0100 Subject: [PATCH] fix CodeLineMustNotEndWithWhitespace --- OpenRA.Game/FileFormats/AudLoader.cs | 6 +++--- OpenRA.Game/FileFormats/ImaAdpcmLoader.cs | 2 +- OpenRA.Game/FileFormats/VqaReader.cs | 8 ++++---- OpenRA.Game/FileFormats/WavLoader.cs | 2 +- OpenRA.Game/GameInformation.cs | 2 +- OpenRA.Game/MiniYaml.cs | 2 +- OpenRA.Game/Network/Order.cs | 2 +- OpenRA.Game/Widgets/ButtonWidget.cs | 2 +- .../Traits/SupportPowers/IonCannonPower.cs | 8 ++++---- .../Traits/Render/WithMuzzleFlash.cs | 2 +- .../Activities/HarvesterDockSequence.cs | 2 +- OpenRA.Mods.RA/Traits/TransformOnPassenger.cs | 2 +- OpenRA.Mods.RA/Widgets/Logic/MusicPlayerLogic.cs | 2 +- .../Widgets/Logic/ObserverStatsLogic.cs | 16 ++++++++-------- OpenRA.Renderer.Sdl2/MultiTapDetection.cs | 2 +- OpenRA.TilesetBuilder/FormBuilder.cs | 4 ++-- OpenRA.TilesetBuilder/Program.cs | 2 +- Settings.StyleCop | 5 ----- 18 files changed, 33 insertions(+), 38 deletions(-) diff --git a/OpenRA.Game/FileFormats/AudLoader.cs b/OpenRA.Game/FileFormats/AudLoader.cs index 32bbe0dda3..a2d7579463 100644 --- a/OpenRA.Game/FileFormats/AudLoader.cs +++ b/OpenRA.Game/FileFormats/AudLoader.cs @@ -45,8 +45,8 @@ namespace OpenRA.FileFormats public static class AudLoader { static int[] indexAdjust = { -1, -1, -1, -1, 2, 4, 6, 8 }; - static int[] stepTable = - { + static int[] stepTable = + { 7, 8, 9, 10, 11, 12, 13, 14, 16, 17, 19, 21, 23, 25, 28, 31, 34, 37, 41, 45, 50, 55, 60, 66, 73, 80, 88, @@ -56,7 +56,7 @@ namespace OpenRA.FileFormats 1282, 1411, 1552, 1707, 1878, 2066, 2272, 2499, 2749, 3024, 3327, 3660, 4026, 4428, 4871, 5358, 5894, 6484, 7132, 7845, 8630, 9493, 10442, 11487, 12635, 13899, 15289, - 16818, 18500, 20350, 22385, 24623, 27086, 29794, 32767 + 16818, 18500, 20350, 22385, 24623, 27086, 29794, 32767 }; static short DecodeSample(byte b, ref int index, ref int current) diff --git a/OpenRA.Game/FileFormats/ImaAdpcmLoader.cs b/OpenRA.Game/FileFormats/ImaAdpcmLoader.cs index bd37ae56fe..d30d8a56c5 100644 --- a/OpenRA.Game/FileFormats/ImaAdpcmLoader.cs +++ b/OpenRA.Game/FileFormats/ImaAdpcmLoader.cs @@ -43,7 +43,7 @@ namespace OpenRA.FileFormats 1282, 1411, 1552, 1707, 1878, 2066, 2272, 2499, 2749, 3024, 3327, 3660, 4026, 4428, 4871, 5358, 5894, 6484, 7132, 7845, 8630, 9493, 10442, 11487, 12635, 13899, 15289, - 16818, 18500, 20350, 22385, 24623, 27086, 29794, 32767 + 16818, 18500, 20350, 22385, 24623, 27086, 29794, 32767 }; static short DecodeImaAdpcmSample(byte b, ref int index, ref int current) diff --git a/OpenRA.Game/FileFormats/VqaReader.cs b/OpenRA.Game/FileFormats/VqaReader.cs index 0264bfbd43..f709dda669 100644 --- a/OpenRA.Game/FileFormats/VqaReader.cs +++ b/OpenRA.Game/FileFormats/VqaReader.cs @@ -73,7 +73,7 @@ namespace OpenRA.FileFormats /*var length2 = */stream.ReadUInt32(); /*var version = */stream.ReadUInt16(); - videoFlags = stream.ReadUInt16(); + videoFlags = stream.ReadUInt16(); Frames = stream.ReadUInt16(); Width = stream.ReadUInt16(); Height = stream.ReadUInt16(); @@ -129,7 +129,7 @@ namespace OpenRA.FileFormats type = stream.ReadASCII(4); } else - throw new NotSupportedException("Vqa uses unknown Subtype : {0}".F(type)); + throw new NotSupportedException("Vqa uses unknown Subtype: {0}".F(type)); } /*var length = */stream.ReadUInt16(); @@ -413,7 +413,7 @@ namespace OpenRA.FileFormats if (IsHqVqa) { /* The VP?? chunks of the video file contains an array of instructions for - * how the blocks of the finished frame will be filled with color data blocks + * how the blocks of the finished frame will be filled with color data blocks * contained in the CBF? chunks. */ var p = 0; @@ -424,7 +424,7 @@ namespace OpenRA.FileFormats if (y >= blocks.Y) break; - // The first 3 bits of the short determine the type of instruction with the rest being one or two parameters. + // The first 3 bits of the short determine the type of instruction with the rest being one or two parameters. var val = (int)origData[p++]; val |= origData[p++] << 8; var para_A = val & 0x1fff; diff --git a/OpenRA.Game/FileFormats/WavLoader.cs b/OpenRA.Game/FileFormats/WavLoader.cs index 7578401f22..cdd47ceefe 100644 --- a/OpenRA.Game/FileFormats/WavLoader.cs +++ b/OpenRA.Game/FileFormats/WavLoader.cs @@ -129,7 +129,7 @@ namespace OpenRA.FileFormats // Decode each block of IMA ADPCM data in RawOutput for (var block = 0; block < numBlocks; block++) { - // Each block starts with a initial state per-channel + // Each block starts with a initial state per-channel for (var c = 0; c < Channels; c++) { predictor[c] = s.ReadInt16(); diff --git a/OpenRA.Game/GameInformation.cs b/OpenRA.Game/GameInformation.cs index 9d44691d4d..d30175121f 100644 --- a/OpenRA.Game/GameInformation.cs +++ b/OpenRA.Game/GameInformation.cs @@ -134,7 +134,7 @@ namespace OpenRA public class Player { - // Start-up information + // Start-up information public int ClientIndex; // The player name, not guaranteed to be unique. diff --git a/OpenRA.Game/MiniYaml.cs b/OpenRA.Game/MiniYaml.cs index 153c746dda..16fe8196f6 100755 --- a/OpenRA.Game/MiniYaml.cs +++ b/OpenRA.Game/MiniYaml.cs @@ -187,7 +187,7 @@ namespace OpenRA default: textStart = true; break; - } + } } var t = line.Substring(cp); diff --git a/OpenRA.Game/Network/Order.cs b/OpenRA.Game/Network/Order.cs index fbdb396141..04b12b7bbc 100755 --- a/OpenRA.Game/Network/Order.cs +++ b/OpenRA.Game/Network/Order.cs @@ -195,7 +195,7 @@ namespace OpenRA switch (OrderString) { - /* + /* * Format: * u8: orderID. * 0xFF: Full serialized order. diff --git a/OpenRA.Game/Widgets/ButtonWidget.cs b/OpenRA.Game/Widgets/ButtonWidget.cs index 7e57e5ca78..7714572a23 100644 --- a/OpenRA.Game/Widgets/ButtonWidget.cs +++ b/OpenRA.Game/Widgets/ButtonWidget.cs @@ -48,7 +48,7 @@ namespace OpenRA.Widgets Lazy tooltipContainer; [Translate] public string TooltipText; - public Func GetTooltipText; + public Func GetTooltipText; // Equivalent to OnMouseUp, but without an input arg public Action OnClick = () => { }; diff --git a/OpenRA.Mods.Cnc/Traits/SupportPowers/IonCannonPower.cs b/OpenRA.Mods.Cnc/Traits/SupportPowers/IonCannonPower.cs index 7d0c42a258..291d163308 100644 --- a/OpenRA.Mods.Cnc/Traits/SupportPowers/IonCannonPower.cs +++ b/OpenRA.Mods.Cnc/Traits/SupportPowers/IonCannonPower.cs @@ -21,17 +21,17 @@ namespace OpenRA.Mods.Cnc.Traits [ActorReference] [Desc("Actor to spawn when the attack starts")] public readonly string CameraActor = null; - + [Desc("Amount of time to keep the camera alive")] public readonly int CameraRemoveDelay = 25; - + [Desc("Effect sequence to display")] public readonly string Effect = "ionsfx"; public readonly string EffectPalette = "effect"; - + [Desc("Which weapon to fire")] public readonly string Weapon = "IonCannon"; - + [Desc("Apply the weapon impact this many ticks into the effect")] public readonly int WeaponDelay = 7; diff --git a/OpenRA.Mods.Common/Traits/Render/WithMuzzleFlash.cs b/OpenRA.Mods.Common/Traits/Render/WithMuzzleFlash.cs index 5ce14c5025..8e8a4eea81 100644 --- a/OpenRA.Mods.Common/Traits/Render/WithMuzzleFlash.cs +++ b/OpenRA.Mods.Common/Traits/Render/WithMuzzleFlash.cs @@ -50,7 +50,7 @@ namespace OpenRA.Mods.Common.Traits var turreted = self.TraitsImplementing() .FirstOrDefault(t => t.Name == arm.Info.Turret); - // Workaround for broken ternary operators in certain versions of mono (3.10 and + // Workaround for broken ternary operators in certain versions of mono (3.10 and // certain versions of the 3.8 series): https://bugzilla.xamarin.com/show_bug.cgi?id=23319 if (turreted != null) getFacing = () => turreted.TurretFacing; diff --git a/OpenRA.Mods.RA/Activities/HarvesterDockSequence.cs b/OpenRA.Mods.RA/Activities/HarvesterDockSequence.cs index 34c7549963..7d414d97c7 100644 --- a/OpenRA.Mods.RA/Activities/HarvesterDockSequence.cs +++ b/OpenRA.Mods.RA/Activities/HarvesterDockSequence.cs @@ -29,7 +29,7 @@ namespace OpenRA.Mods.RA.Activities protected readonly int DragLength; protected readonly WPos StartDrag; protected readonly WPos EndDrag; - + protected State dockingState; public HarvesterDockSequence(Actor self, Actor refinery, int dockAngle, bool isDragRequired, WVec dragOffset, int dragLength) diff --git a/OpenRA.Mods.RA/Traits/TransformOnPassenger.cs b/OpenRA.Mods.RA/Traits/TransformOnPassenger.cs index 532768d0a5..10ccb4a24c 100644 --- a/OpenRA.Mods.RA/Traits/TransformOnPassenger.cs +++ b/OpenRA.Mods.RA/Traits/TransformOnPassenger.cs @@ -1,7 +1,7 @@ #region Copyright & License Information /* * Copyright 2007-2015 The OpenRA Developers (see AUTHORS) - * This file is part of OpenRA, which is free software. It is made + * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation. For more information, * see COPYING. diff --git a/OpenRA.Mods.RA/Widgets/Logic/MusicPlayerLogic.cs b/OpenRA.Mods.RA/Widgets/Logic/MusicPlayerLogic.cs index 40466bffe8..26143a3810 100644 --- a/OpenRA.Mods.RA/Widgets/Logic/MusicPlayerLogic.cs +++ b/OpenRA.Mods.RA/Widgets/Logic/MusicPlayerLogic.cs @@ -100,7 +100,7 @@ namespace OpenRA.Mods.RA.Widgets.Logic var songWatcher = widget.GetOrNull("SONG_WATCHER"); if (songWatcher != null) { - songWatcher.OnTick = () => + songWatcher.OnTick = () => { if (Sound.CurrentMusic == null || currentSong == Sound.CurrentMusic) return; diff --git a/OpenRA.Mods.RA/Widgets/Logic/ObserverStatsLogic.cs b/OpenRA.Mods.RA/Widgets/Logic/ObserverStatsLogic.cs index f20fd64340..e99df26f07 100644 --- a/OpenRA.Mods.RA/Widgets/Logic/ObserverStatsLogic.cs +++ b/OpenRA.Mods.RA/Widgets/Logic/ObserverStatsLogic.cs @@ -72,7 +72,7 @@ namespace OpenRA.Mods.RA.Widgets.Logic { var options = new List { - new StatsDropDownOption + new StatsDropDownOption { Title = "Basic", IsSelected = () => basicStatsHeaders.Visible, @@ -83,33 +83,33 @@ namespace OpenRA.Mods.RA.Widgets.Logic DisplayStats(BasicStats); } }, - new StatsDropDownOption + new StatsDropDownOption { Title = "Economy", IsSelected = () => economyStatsHeaders.Visible, - OnClick = () => + OnClick = () => { ClearStats(); statsDropDown.GetText = () => "Economy"; DisplayStats(EconomyStats); } }, - new StatsDropDownOption + new StatsDropDownOption { Title = "Production", IsSelected = () => productionStatsHeaders.Visible, - OnClick = () => + OnClick = () => { ClearStats(); statsDropDown.GetText = () => "Production"; DisplayStats(ProductionStats); } }, - new StatsDropDownOption + new StatsDropDownOption { Title = "Combat", IsSelected = () => combatStatsHeaders.Visible, - OnClick = () => + OnClick = () => { ClearStats(); statsDropDown.GetText = () => "Combat"; @@ -120,7 +120,7 @@ namespace OpenRA.Mods.RA.Widgets.Logic { Title = "Earnings (graph)", IsSelected = () => earnedThisMinuteGraphHeaders.Visible, - OnClick = () => + OnClick = () => { ClearStats(); statsDropDown.GetText = () => "Earnings (graph)"; diff --git a/OpenRA.Renderer.Sdl2/MultiTapDetection.cs b/OpenRA.Renderer.Sdl2/MultiTapDetection.cs index 2a4fc75ca0..4948bcb75b 100644 --- a/OpenRA.Renderer.Sdl2/MultiTapDetection.cs +++ b/OpenRA.Renderer.Sdl2/MultiTapDetection.cs @@ -1,7 +1,7 @@ #region Copyright & License Information /* * Copyright 2007-2015 The OpenRA Developers (see AUTHORS) - * This file is part of OpenRA, which is free software. It is made + * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation. For more information, * see COPYING. diff --git a/OpenRA.TilesetBuilder/FormBuilder.cs b/OpenRA.TilesetBuilder/FormBuilder.cs index f5c983fdcd..a03f16ea85 100644 --- a/OpenRA.TilesetBuilder/FormBuilder.cs +++ b/OpenRA.TilesetBuilder/FormBuilder.cs @@ -1,7 +1,7 @@ #region Copyright & License Information /* * Copyright 2007-2015 The OpenRA Developers (see AUTHORS) - * This file is part of OpenRA, which is free software. It is made + * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation. For more information, * see COPYING. @@ -271,7 +271,7 @@ namespace OpenRA.TilesetBuilder bw.Write((uint)0); // filesize placeholder bw.Flush(); bw.Write((uint)ms.Position + 24); // image start - bw.Write((uint)0); // 0 (32bits) + bw.Write((uint)0); // 0 (32bits) bw.Write((uint)0x2c730f8c); // magic? bw.Write((uint)0); // flags start bw.Write((uint)0); // walk start diff --git a/OpenRA.TilesetBuilder/Program.cs b/OpenRA.TilesetBuilder/Program.cs index 9395b550ad..ee0c3e5b64 100644 --- a/OpenRA.TilesetBuilder/Program.cs +++ b/OpenRA.TilesetBuilder/Program.cs @@ -1,7 +1,7 @@ #region Copyright & License Information /* * Copyright 2007-2015 The OpenRA Developers (see AUTHORS) - * This file is part of OpenRA, which is free software. It is made + * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation. For more information, * see COPYING. diff --git a/Settings.StyleCop b/Settings.StyleCop index 02b1e4185b..e5aa9112b0 100644 --- a/Settings.StyleCop +++ b/Settings.StyleCop @@ -362,11 +362,6 @@ - - - False - - False