Index: Core/Common/src/Core.Common.Controls/Core.Common.Controls.csproj =================================================================== diff -u -ra048dc4662f1eb83e4e8cd127790473f01470263 -r03a91e1d4a5b97092a09071da67cb5929ef9993e --- Core/Common/src/Core.Common.Controls/Core.Common.Controls.csproj (.../Core.Common.Controls.csproj) (revision a048dc4662f1eb83e4e8cd127790473f01470263) +++ Core/Common/src/Core.Common.Controls/Core.Common.Controls.csproj (.../Core.Common.Controls.csproj) (revision 03a91e1d4a5b97092a09071da67cb5929ef9993e) @@ -67,6 +67,9 @@ AllRules.ruleset + + obj\x86\Debug\Core.Common.Controls.dll + 3.5 @@ -82,6 +85,9 @@ + + Component + UserControl Index: Core/Common/src/Core.Common.Controls/DataGrid/DataGridViewControl.Designer.cs =================================================================== diff -u -ra048dc4662f1eb83e4e8cd127790473f01470263 -r03a91e1d4a5b97092a09071da67cb5929ef9993e --- Core/Common/src/Core.Common.Controls/DataGrid/DataGridViewControl.Designer.cs (.../DataGridViewControl.Designer.cs) (revision a048dc4662f1eb83e4e8cd127790473f01470263) +++ Core/Common/src/Core.Common.Controls/DataGrid/DataGridViewControl.Designer.cs (.../DataGridViewControl.Designer.cs) (revision 03a91e1d4a5b97092a09071da67cb5929ef9993e) @@ -30,7 +30,7 @@ /// private void InitializeComponent() { - this.dataGridView = new System.Windows.Forms.DataGridView(); + this.dataGridView = new Core.Common.Controls.DataGrid.DoubleBufferedDataGridView(); ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit(); this.SuspendLayout(); // @@ -66,6 +66,7 @@ #endregion - private System.Windows.Forms.DataGridView dataGridView; + private DoubleBufferedDataGridView dataGridView; + } } Index: Core/Common/src/Core.Common.Controls/DataGrid/DoubleBufferedDataGridView.cs =================================================================== diff -u --- Core/Common/src/Core.Common.Controls/DataGrid/DoubleBufferedDataGridView.cs (revision 0) +++ Core/Common/src/Core.Common.Controls/DataGrid/DoubleBufferedDataGridView.cs (revision 03a91e1d4a5b97092a09071da67cb5929ef9993e) @@ -0,0 +1,42 @@ +// Copyright (C) Stichting Deltares 2016. All rights reserved. +// +// This file is part of Ringtoets. +// +// Ringtoets is free software: you can redistribute it and/or modify +// it under the terms of the GNU Lesser General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public License +// along with this program. If not, see . +// +// All names, logos, and references to "Deltares" are registered trademarks of +// Stichting Deltares and remain full property of Stichting Deltares at all times. +// All rights reserved. + +using System.Windows.Forms; + +namespace Core.Common.Controls.DataGrid +{ + /// + /// Double buffered version of. + /// + /// + /// Also see http://stackoverflow.com/questions/252689/why-does-the-doublebuffered-property-default-to-false-on-a-datagridview-and-why. + /// + public sealed class DoubleBufferedDataGridView : DataGridView + { + /// + /// Creates a new instance of . + /// + public DoubleBufferedDataGridView() + { + DoubleBuffered = true; + } + } +} Index: Core/Common/test/Core.Common.Controls.Test/Core.Common.Controls.Test.csproj =================================================================== diff -u -r5341ef6e47326ef870d7e6f918c9085d7073d3c9 -r03a91e1d4a5b97092a09071da67cb5929ef9993e --- Core/Common/test/Core.Common.Controls.Test/Core.Common.Controls.Test.csproj (.../Core.Common.Controls.Test.csproj) (revision 5341ef6e47326ef870d7e6f918c9085d7073d3c9) +++ Core/Common/test/Core.Common.Controls.Test/Core.Common.Controls.Test.csproj (.../Core.Common.Controls.Test.csproj) (revision 03a91e1d4a5b97092a09071da67cb5929ef9993e) @@ -56,6 +56,7 @@ + Index: Core/Common/test/Core.Common.Controls.Test/DataGrid/DataGridViewControlTest.cs =================================================================== diff -u -rd48d2c62b4a2d2f177e1725e1b84e54a8d49327f -r03a91e1d4a5b97092a09071da67cb5929ef9993e --- Core/Common/test/Core.Common.Controls.Test/DataGrid/DataGridViewControlTest.cs (.../DataGridViewControlTest.cs) (revision d48d2c62b4a2d2f177e1725e1b84e54a8d49327f) +++ Core/Common/test/Core.Common.Controls.Test/DataGrid/DataGridViewControlTest.cs (.../DataGridViewControlTest.cs) (revision 03a91e1d4a5b97092a09071da67cb5929ef9993e) @@ -46,7 +46,7 @@ Assert.AreEqual(1, control.Controls.Count); var dataGridView = control.Controls[0]; - Assert.IsInstanceOf(dataGridView); + Assert.IsInstanceOf(dataGridView); Assert.AreEqual(DockStyle.Fill, dataGridView.Dock); } } Index: Core/Common/test/Core.Common.Controls.Test/DataGrid/DoubleBufferedDataGridViewTest.cs =================================================================== diff -u --- Core/Common/test/Core.Common.Controls.Test/DataGrid/DoubleBufferedDataGridViewTest.cs (revision 0) +++ Core/Common/test/Core.Common.Controls.Test/DataGrid/DoubleBufferedDataGridViewTest.cs (revision 03a91e1d4a5b97092a09071da67cb5929ef9993e) @@ -0,0 +1,41 @@ +// Copyright (C) Stichting Deltares 2016. All rights reserved. +// +// This file is part of Ringtoets. +// +// Ringtoets is free software: you can redistribute it and/or modify +// it under the terms of the GNU Lesser General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public License +// along with this program. If not, see . +// +// All names, logos, and references to "Deltares" are registered trademarks of +// Stichting Deltares and remain full property of Stichting Deltares at all times. +// All rights reserved. + +using System.Windows.Forms; +using Core.Common.Controls.DataGrid; +using NUnit.Framework; + +namespace Core.Common.Controls.Test.DataGrid +{ + [TestFixture] + public class DoubleBufferedDataGridViewTest + { + [Test] + public void Constructor_DefaultValues() + { + // Call + var dataGridView = new DoubleBufferedDataGridView(); + + // Assert + Assert.IsInstanceOf(dataGridView); + } + } +} \ No newline at end of file