Index: Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/PropertyClasses/DikeProfileProperties.cs =================================================================== diff -u -r0e541f9ed4d56646332e86aea1b3c699c650563b -rcba6c270ea323936b751ca8f8572075298f594f9 --- Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/PropertyClasses/DikeProfileProperties.cs (.../DikeProfileProperties.cs) (revision 0e541f9ed4d56646332e86aea1b3c699c650563b) +++ Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/PropertyClasses/DikeProfileProperties.cs (.../DikeProfileProperties.cs) (revision cba6c270ea323936b751ca8f8572075298f594f9) @@ -37,12 +37,12 @@ public class DikeProfileProperties : ObjectProperties { private const int namePropertyIndex = 1; - private const int orientationPropertyIndex = 2; - private const int breakWaterPropertyIndex = 3; - private const int foreshorePropertyIndex = 4; - private const int dikeGeometryPropertyIndex = 5; - private const int dikeHeightPropertyIndex = 6; - private const int worldReferencePointPropertyIndex = 7; + private const int worldReferencePointPropertyIndex = 2; + private const int orientationPropertyIndex = 3; + private const int breakWaterPropertyIndex = 4; + private const int foreshorePropertyIndex = 5; + private const int dikeGeometryPropertyIndex = 6; + private const int dikeHeightPropertyIndex = 7; [PropertyOrder(namePropertyIndex)] [ResourcesCategory(typeof(RingtoetsCommonDataResources), "Categories_General")] @@ -56,6 +56,20 @@ } } + [PropertyOrder(worldReferencePointPropertyIndex)] + [ResourcesCategory(typeof(GrassCoverErosionInwardsFormsResources), "Categories_Schematisation")] + [ResourcesDisplayName(typeof(GrassCoverErosionInwardsFormsResources), "WorldReferencePoint_DisplayName")] + [ResourcesDescription(typeof(GrassCoverErosionInwardsFormsResources), "WorldReferencePoint_Description")] + public Point2D WorldReferencePoint + { + get + { + return new Point2D( + new RoundedDouble(0, data.WorldReferencePoint.X), + new RoundedDouble(0, data.WorldReferencePoint.Y)); + } + } + [PropertyOrder(orientationPropertyIndex)] [ResourcesCategory(typeof(GrassCoverErosionInwardsFormsResources), "Categories_Schematisation")] [ResourcesDisplayName(typeof(GrassCoverErosionInwardsFormsResources), "Orientation_DisplayName")] @@ -127,19 +141,5 @@ return data.DikeHeight; } } - - [PropertyOrder(worldReferencePointPropertyIndex)] - [ResourcesCategory(typeof(GrassCoverErosionInwardsFormsResources), "Categories_Schematisation")] - [ResourcesDisplayName(typeof(GrassCoverErosionInwardsFormsResources), "WorldReferencePoint_DisplayName")] - [ResourcesDescription(typeof(GrassCoverErosionInwardsFormsResources), "WorldReferencePoint_Description")] - public Point2D WorldReferencePoint - { - get - { - return new Point2D( - new RoundedDouble(0, data.WorldReferencePoint.X), - new RoundedDouble(0, data.WorldReferencePoint.Y)); - } - } } } \ No newline at end of file Index: Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/PropertyClasses/GrassCoverErosionInwardsInputContextProperties.cs =================================================================== diff -u -r0e541f9ed4d56646332e86aea1b3c699c650563b -rcba6c270ea323936b751ca8f8572075298f594f9 --- Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/PropertyClasses/GrassCoverErosionInwardsInputContextProperties.cs (.../GrassCoverErosionInwardsInputContextProperties.cs) (revision 0e541f9ed4d56646332e86aea1b3c699c650563b) +++ Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/PropertyClasses/GrassCoverErosionInwardsInputContextProperties.cs (.../GrassCoverErosionInwardsInputContextProperties.cs) (revision cba6c270ea323936b751ca8f8572075298f594f9) @@ -43,15 +43,15 @@ public class GrassCoverErosionInwardsInputContextProperties : ObjectProperties { private const int dikeProfilePropertyIndex = 1; - private const int orientationPropertyIndex = 2; - private const int breakWaterPropertyIndex = 3; - private const int foreshorePropertyIndex = 4; - private const int dikeGeometryPropertyIndex = 5; - private const int dikeHeightPropertyIndex = 6; - private const int criticalFlowRatePropertyIndex = 7; - private const int hydraulicBoundaryLocationPropertyIndex = 8; - private const int calculateDikeHeightPropertyIndex = 9; - private const int worldReferencePointPropertyIndex = 10; + private const int worldReferencePointPropertyIndex = 2; + private const int orientationPropertyIndex = 3; + private const int breakWaterPropertyIndex = 4; + private const int foreshorePropertyIndex = 5; + private const int dikeGeometryPropertyIndex = 6; + private const int dikeHeightPropertyIndex = 7; + private const int criticalFlowRatePropertyIndex = 8; + private const int hydraulicBoundaryLocationPropertyIndex = 9; + private const int calculateDikeHeightPropertyIndex = 10; [PropertyOrder(dikeProfilePropertyIndex)] [Editor(typeof(GrassCoverErosionInwardsInputContextDikeProfileEditor), typeof(UITypeEditor))] @@ -72,6 +72,21 @@ } } + [PropertyOrder(worldReferencePointPropertyIndex)] + [ResourcesCategory(typeof(Resources), "Categories_Schematisation")] + [ResourcesDisplayName(typeof(Resources), "WorldReferencePoint_DisplayName")] + [ResourcesDescription(typeof(Resources), "WorldReferencePoint_Description")] + public Point2D WorldReferencePoint + { + get + { + return data.WrappedData.DikeProfile == null ? null : + new Point2D( + new RoundedDouble(0, data.WrappedData.DikeProfile.WorldReferencePoint.X), + new RoundedDouble(0, data.WrappedData.DikeProfile.WorldReferencePoint.Y)); + } + } + [DynamicReadOnly] [PropertyOrder(orientationPropertyIndex)] [ResourcesCategory(typeof(Resources), "Categories_Schematisation")] @@ -173,21 +188,6 @@ } } - [PropertyOrder(worldReferencePointPropertyIndex)] - [ResourcesCategory(typeof(Resources), "Categories_Schematisation")] - [ResourcesDisplayName(typeof(Resources), "WorldReferencePoint_DisplayName")] - [ResourcesDescription(typeof(Resources), "WorldReferencePoint_Description")] - public Point2D WorldReferencePoint - { - get - { - return data.WrappedData.DikeProfile == null ? null : - new Point2D( - new RoundedDouble(0, data.WrappedData.DikeProfile.WorldReferencePoint.X), - new RoundedDouble(0, data.WrappedData.DikeProfile.WorldReferencePoint.Y)); - } - } - [PropertyOrder(criticalFlowRatePropertyIndex)] [TypeConverter(typeof(ExpandableObjectConverter))] [ResourcesCategory(typeof(Resources), "Categories_CriticalValues")] Index: Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/PropertyClasses/DikeProfilePropertiesTest.cs =================================================================== diff -u -r0e541f9ed4d56646332e86aea1b3c699c650563b -rcba6c270ea323936b751ca8f8572075298f594f9 --- Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/PropertyClasses/DikeProfilePropertiesTest.cs (.../DikeProfilePropertiesTest.cs) (revision 0e541f9ed4d56646332e86aea1b3c699c650563b) +++ Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/PropertyClasses/DikeProfilePropertiesTest.cs (.../DikeProfilePropertiesTest.cs) (revision cba6c270ea323936b751ca8f8572075298f594f9) @@ -96,6 +96,13 @@ Assert.AreEqual("Naam", nameProperty.DisplayName); Assert.AreEqual("Naam van het dijkprofiel.", nameProperty.Description); + PropertyDescriptor worldReferencePointProperty = dynamicProperties[worldReferencePointPropertyIndex]; + Assert.IsNotNull(worldReferencePointProperty); + Assert.IsTrue(worldReferencePointProperty.IsReadOnly); + Assert.AreEqual("Schematisatie", worldReferencePointProperty.Category); + Assert.AreEqual("Locatie (RD) [m]", worldReferencePointProperty.DisplayName); + Assert.AreEqual("De coördinaten van de locatie in het Rijksdriehoeksstelsel.", worldReferencePointProperty.Description); + PropertyDescriptor orientationProperty = dynamicProperties[orientationPropertyIndex]; Assert.IsNotNull(orientationProperty); Assert.IsTrue(orientationProperty.IsReadOnly); @@ -133,21 +140,14 @@ Assert.AreEqual("Schematisatie", dikeHeightProperty.Category); Assert.AreEqual("Dijkhoogte [m+NAP]", dikeHeightProperty.DisplayName); Assert.AreEqual("De hoogte van de dijk [m+NAP].", dikeHeightProperty.Description); - - PropertyDescriptor worldReferencePointProperty = dynamicProperties[worldReferencePointPropertyIndex]; - Assert.IsNotNull(worldReferencePointProperty); - Assert.IsTrue(worldReferencePointProperty.IsReadOnly); - Assert.AreEqual("Schematisatie", worldReferencePointProperty.Category); - Assert.AreEqual("Locatie (RD) [m]", worldReferencePointProperty.DisplayName); - Assert.AreEqual("De coördinaten van de locatie in het Rijksdriehoeksstelsel.", worldReferencePointProperty.Description); } private const int namePropertyIndex = 0; - private const int orientationPropertyIndex = 1; - private const int breakWaterPropertyIndex = 2; - private const int foreshorePropertyIndex = 3; - private const int dikeGeometryPropertyIndex = 4; - private const int dikeHeightPropertyIndex = 5; - private const int worldReferencePointPropertyIndex = 6; + private const int worldReferencePointPropertyIndex = 1; + private const int orientationPropertyIndex = 2; + private const int breakWaterPropertyIndex = 3; + private const int foreshorePropertyIndex = 4; + private const int dikeGeometryPropertyIndex = 5; + private const int dikeHeightPropertyIndex = 6; } } \ No newline at end of file Index: Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/PropertyClasses/GrassCoverErosionInwardsInputContextPropertiesTest.cs =================================================================== diff -u -r0e541f9ed4d56646332e86aea1b3c699c650563b -rcba6c270ea323936b751ca8f8572075298f594f9 --- Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/PropertyClasses/GrassCoverErosionInwardsInputContextPropertiesTest.cs (.../GrassCoverErosionInwardsInputContextPropertiesTest.cs) (revision 0e541f9ed4d56646332e86aea1b3c699c650563b) +++ Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/PropertyClasses/GrassCoverErosionInwardsInputContextPropertiesTest.cs (.../GrassCoverErosionInwardsInputContextPropertiesTest.cs) (revision cba6c270ea323936b751ca8f8572075298f594f9) @@ -212,6 +212,13 @@ Assert.AreEqual("Dijkprofiel", dikeProfileProperty.DisplayName); Assert.AreEqual("De schematisatie van het dijkprofiel.", dikeProfileProperty.Description); + PropertyDescriptor worldReferencePointProperty = dynamicProperties[worldReferencePointPropertyIndex]; + Assert.IsNotNull(worldReferencePointProperty); + Assert.IsTrue(worldReferencePointProperty.IsReadOnly); + Assert.AreEqual("Schematisatie", worldReferencePointProperty.Category); + Assert.AreEqual("Locatie (RD) [m]", worldReferencePointProperty.DisplayName); + Assert.AreEqual("De coördinaten van de locatie in het Rijksdriehoeksstelsel.", worldReferencePointProperty.Description); + PropertyDescriptor orientationProperty = dynamicProperties[orientationPropertyIndex]; Assert.IsNotNull(orientationProperty); Assert.AreEqual(!withDikeProfile, orientationProperty.IsReadOnly); @@ -270,25 +277,18 @@ Assert.AreEqual("HBN berekenen", dynamicProperties[calculateDikeHeightPropertyIndex].DisplayName); Assert.AreEqual("Geeft aan of ook het Hydraulisch Belasting Niveau (HBN) moet worden berekend.", dynamicProperties[calculateDikeHeightPropertyIndex].Description); - PropertyDescriptor worldReferencePointProperty = dynamicProperties[worldReferencePointPropertyIndex]; - Assert.IsNotNull(worldReferencePointProperty); - Assert.IsTrue(worldReferencePointProperty.IsReadOnly); - Assert.AreEqual("Schematisatie", worldReferencePointProperty.Category); - Assert.AreEqual("Locatie (RD) [m]", worldReferencePointProperty.DisplayName); - Assert.AreEqual("De coördinaten van de locatie in het Rijksdriehoeksstelsel.", worldReferencePointProperty.Description); - mockRepository.VerifyAll(); } private const int dikeProfilePropertyIndex = 0; - private const int orientationPropertyIndex = 1; - private const int breakWaterPropertyIndex = 2; - private const int foreshorePropertyIndex = 3; - private const int dikeGeometryPropertyIndex = 4; - private const int dikeHeightPropertyIndex = 5; - private const int criticalFlowRatePropertyIndex = 6; - private const int hydraulicBoundaryLocationPropertyIndex = 7; - private const int calculateDikeHeightPropertyIndex = 8; - private const int worldReferencePointPropertyIndex = 9; + private const int worldReferencePointPropertyIndex = 1; + private const int orientationPropertyIndex = 2; + private const int breakWaterPropertyIndex = 3; + private const int foreshorePropertyIndex = 4; + private const int dikeGeometryPropertyIndex = 5; + private const int dikeHeightPropertyIndex = 6; + private const int criticalFlowRatePropertyIndex = 7; + private const int hydraulicBoundaryLocationPropertyIndex = 8; + private const int calculateDikeHeightPropertyIndex = 9; } } \ No newline at end of file