summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Controls
diff options
context:
space:
mode:
authorStephane Delcroix <stephane@delcroix.org>2017-02-06 15:18:16 +0100
committerStephane Delcroix <stephane@delcroix.org>2017-02-06 15:18:16 +0100
commitfaa6eae8e72d810c8d16dd92e02b305dbf35548c (patch)
tree78a91ae8be6dd37b03c2f345b54c07472d7f58b9 /Xamarin.Forms.Controls
parentfc7d556848e731902d096953c9b4fb28a2466e6b (diff)
downloadxamarin-forms-faa6eae8e72d810c8d16dd92e02b305dbf35548c.tar.gz
xamarin-forms-faa6eae8e72d810c8d16dd92e02b305dbf35548c.tar.bz2
xamarin-forms-faa6eae8e72d810c8d16dd92e02b305dbf35548c.zip
Revert "[*] ScaleX and ScaleY"
This reverts commit fc7d556848e731902d096953c9b4fb28a2466e6b.
Diffstat (limited to 'Xamarin.Forms.Controls')
-rw-r--r--Xamarin.Forms.Controls/GalleryPages/ScaleRotate.cs37
1 files changed, 6 insertions, 31 deletions
diff --git a/Xamarin.Forms.Controls/GalleryPages/ScaleRotate.cs b/Xamarin.Forms.Controls/GalleryPages/ScaleRotate.cs
index 18276d81..e189f839 100644
--- a/Xamarin.Forms.Controls/GalleryPages/ScaleRotate.cs
+++ b/Xamarin.Forms.Controls/GalleryPages/ScaleRotate.cs
@@ -39,41 +39,19 @@ namespace Xamarin.Forms.Controls
scaleSlider.SetBinding(Slider.ValueProperty,
new Binding("Scale", BindingMode.TwoWay));
- // Label and Slider for ScaleX property.
- Label scaleXSliderValue = new Label {
- VerticalTextAlignment = TextAlignment.Center
- };
- Grid.SetRow(scaleXSliderValue, 1);
- Grid.SetColumn(scaleXSliderValue, 0);
-
- Slider scaleXSlider = new Slider {
- Maximum = 10
- };
- Grid.SetRow(scaleXSlider, 1);
- Grid.SetColumn(scaleXSlider, 1);
-
- // Set Bindings.
- scaleXSliderValue.BindingContext = scaleXSlider;
- scaleXSliderValue.SetBinding(Label.TextProperty,
- new Binding("Value", BindingMode.OneWay, null, null, "ScaleX = {0:F1}"));
-
- scaleXSlider.BindingContext = label;
- scaleXSlider.SetBinding(Slider.ValueProperty,
- new Binding("ScaleX", BindingMode.TwoWay));
-
// Label and Slider for Rotation property.
Label rotationSliderValue = new Label
{
VerticalTextAlignment = TextAlignment.Center
};
- Grid.SetRow(rotationSliderValue, 2);
+ Grid.SetRow(rotationSliderValue, 1);
Grid.SetColumn(rotationSliderValue, 0);
Slider rotationSlider = new Slider
{
Maximum = 360
};
- Grid.SetRow(rotationSlider, 2);
+ Grid.SetRow(rotationSlider, 1);
Grid.SetColumn(rotationSlider, 1);
// Set Bindings.
@@ -90,7 +68,7 @@ namespace Xamarin.Forms.Controls
{
VerticalTextAlignment = TextAlignment.Center
};
- Grid.SetRow(anchorxStepperValue, 3);
+ Grid.SetRow(anchorxStepperValue, 2);
Grid.SetColumn(anchorxStepperValue, 0);
Stepper anchorxStepper = new Stepper
@@ -99,7 +77,7 @@ namespace Xamarin.Forms.Controls
Minimum = -1,
Increment = 0.5
};
- Grid.SetRow(anchorxStepper, 3);
+ Grid.SetRow(anchorxStepper, 2);
Grid.SetColumn(anchorxStepper, 1);
// Set bindings.
@@ -116,7 +94,7 @@ namespace Xamarin.Forms.Controls
{
VerticalTextAlignment = TextAlignment.Center
};
- Grid.SetRow(anchoryStepperValue, 4);
+ Grid.SetRow(anchoryStepperValue, 3);
Grid.SetColumn(anchoryStepperValue, 0);
Stepper anchoryStepper = new Stepper
@@ -125,7 +103,7 @@ namespace Xamarin.Forms.Controls
Minimum = -1,
Increment = 0.5
};
- Grid.SetRow(anchoryStepper, 4);
+ Grid.SetRow(anchoryStepper, 3);
Grid.SetColumn(anchoryStepper, 1);
// Set bindings.
@@ -152,7 +130,6 @@ namespace Xamarin.Forms.Controls
new RowDefinition { Height = GridLength.Auto },
new RowDefinition { Height = GridLength.Auto },
new RowDefinition { Height = GridLength.Auto },
- new RowDefinition { Height = GridLength.Auto },
},
ColumnDefinitions =
{
@@ -163,8 +140,6 @@ namespace Xamarin.Forms.Controls
{
scaleSliderValue,
scaleSlider,
- scaleXSliderValue,
- scaleXSlider,
rotationSliderValue,
rotationSlider,
anchorxStepperValue,