This repository has been archived by the owner on May 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
66 changed files
with
2,441 additions
and
216 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
69 changes: 69 additions & 0 deletions
69
Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue12984.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<controls:TestContentPage | ||
xmlns="http://xamarin.com/schemas/2014/forms" | ||
xmlns:controls="clr-namespace:Xamarin.Forms.Controls" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" | ||
xmlns:d="http://xamarin.com/schemas/2014/forms/design" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
x:Class="Xamarin.Forms.Controls.Issues.Issue12984" | ||
Title="Issue 12984"> | ||
<Grid RowDefinitions="Auto,*"> | ||
<Label | ||
Grid.Row="0" | ||
Padding="12" | ||
BackgroundColor="Black" | ||
TextColor="White" | ||
Text="If the background color of the disabled Button is pink, the test has passed."/> | ||
<StackLayout | ||
Grid.Row="1"> | ||
<Button | ||
Text="Normal Button"> | ||
<VisualStateManager.VisualStateGroups> | ||
<VisualStateGroup x:Name="CommonStates"> | ||
<VisualState x:Name="Normal"> | ||
<VisualState.Setters> | ||
<Setter Property="BackgroundColor" Value="Red" /> | ||
<Setter Property="BorderColor" Value="Yellow" /> | ||
<Setter Property="TextColor" Value="White" /> | ||
<Setter Property="FontSize" Value="Small" /> | ||
</VisualState.Setters> | ||
</VisualState> | ||
<VisualState x:Name="Selected"> | ||
<VisualState.Setters> | ||
<Setter Property="BackgroundColor" Value="Green" /> | ||
<Setter Property="BorderColor" Value="Orange" /> | ||
<Setter Property="TextColor" Value="Yellow" /> | ||
<Setter Property="FontSize" Value="Medium" /> | ||
</VisualState.Setters> | ||
</VisualState> | ||
<VisualState x:Name="Focused"> | ||
<VisualState.Setters> | ||
<Setter Property="BackgroundColor" Value="Blue" /> | ||
<Setter Property="BorderColor" Value="Purple" /> | ||
<Setter Property="TextColor" Value="Yellow" /> | ||
<Setter Property="FontSize" Value="Medium" /> | ||
</VisualState.Setters> | ||
</VisualState> | ||
</VisualStateGroup> | ||
</VisualStateManager.VisualStateGroups> | ||
</Button> | ||
<Button | ||
Text="Disabled Button" | ||
IsEnabled="False"> | ||
<VisualStateManager.VisualStateGroups> | ||
<VisualStateGroup x:Name="CommonStates"> | ||
<VisualState x:Name="Disabled"> | ||
<VisualState.Setters> | ||
<Setter Property="BackgroundColor" Value="Pink" /> | ||
<Setter Property="BorderColor" Value="Orange" /> | ||
<Setter Property="TextColor" Value="Red" /> | ||
<Setter Property="FontSize" Value="Micro" /> | ||
</VisualState.Setters> | ||
</VisualState> | ||
</VisualStateGroup> | ||
</VisualStateManager.VisualStateGroups> | ||
</Button> | ||
</StackLayout> | ||
</Grid> | ||
</controls:TestContentPage> |
32 changes: 32 additions & 0 deletions
32
Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue12984.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
using Xamarin.Forms.CustomAttributes; | ||
using Xamarin.Forms.Internals; | ||
|
||
#if UITEST | ||
using Xamarin.Forms.Core.UITests; | ||
using Xamarin.UITest; | ||
using NUnit.Framework; | ||
#endif | ||
|
||
namespace Xamarin.Forms.Controls.Issues | ||
{ | ||
#if UITEST | ||
[Category(UITestCategories.CollectionView)] | ||
#endif | ||
[Preserve(AllMembers = true)] | ||
[Issue(IssueTracker.Github, 12984, "[Bug][UWP] VisualState Disabled not working on Button", | ||
PlatformAffected.UWP)] | ||
public partial class Issue12984 : TestContentPage | ||
{ | ||
public Issue12984() | ||
{ | ||
#if APP | ||
InitializeComponent(); | ||
#endif | ||
} | ||
|
||
protected override void Init() | ||
{ | ||
|
||
} | ||
} | ||
} |
38 changes: 38 additions & 0 deletions
38
Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue13315.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<local:TestContentPage | ||
xmlns="http://xamarin.com/schemas/2014/forms" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" | ||
xmlns:d="http://xamarin.com/schemas/2014/forms/design" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Title="Test 13315" xmlns:local="using:Xamarin.Forms.Controls" | ||
x:Class="Xamarin.Forms.Controls.Issues.Issue13315"> | ||
<StackLayout> | ||
<Label | ||
Padding="12" | ||
BackgroundColor="Black" | ||
TextColor="White" | ||
Text="If the Paths render exactly the same on all platforms, the test has passed."/> | ||
<Path | ||
Data="M17,13H13V17H11V13H7V11H11V7H13V11H17M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z" | ||
Fill="Blue" | ||
StrokeThickness="0" | ||
Aspect="Uniform" | ||
WidthRequest="100" | ||
HeightRequest="100"/> | ||
<Path | ||
Data="M4,4H7L9,2H15L17,4H20A2,2 0 0,1 22,6V18A2,2 0 0,1 20,20H4A2,2 0 0,1 2,18V6A2,2 0 0,1 4,4M12,7A5,5 0 0,0 7,12A5,5 0 0,0 12,17A5,5 0 0,0 17,12A5,5 0 0,0 12,7M12,9A3,3 0 0,1 15,12A3,3 0 0,1 12,15A3,3 0 0,1 9,12A3,3 0 0,1 12,9Z" | ||
Fill="Red" | ||
StrokeThickness="0" | ||
Aspect="Uniform" | ||
WidthRequest="100" | ||
HeightRequest="100"/> | ||
<Path | ||
Data="M22,16V4A2,2 0 0,0 20,2H8A2,2 0 0,0 6,4V16A2,2 0 0,0 8,18H20A2,2 0 0,0 22,16M11,12L13.03,14.71L16,11L20,16H8M2,6V20A2,2 0 0,0 4,22H18V20H4V6" | ||
Fill="Green" | ||
StrokeThickness="0" | ||
Aspect="Uniform" | ||
WidthRequest="100" | ||
HeightRequest="100"/> | ||
</StackLayout> | ||
</local:TestContentPage> |
27 changes: 27 additions & 0 deletions
27
Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue13315.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
using Xamarin.Forms.CustomAttributes; | ||
|
||
#if UITEST | ||
using Xamarin.UITest; | ||
using NUnit.Framework; | ||
using Xamarin.Forms.Core.UITests; | ||
#endif | ||
|
||
namespace Xamarin.Forms.Controls.Issues | ||
{ | ||
[Issue(IssueTracker.Github, 13315, | ||
"[Bug] Path renders incorrectly on iOS but correctly on Android", | ||
PlatformAffected.iOS)] | ||
public partial class Issue13315 : TestContentPage | ||
{ | ||
public Issue13315() | ||
{ | ||
#if APP | ||
InitializeComponent(); | ||
#endif | ||
} | ||
|
||
protected override void Init() | ||
{ | ||
} | ||
} | ||
} |
48 changes: 48 additions & 0 deletions
48
Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue13670.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<local:TestContentPage | ||
xmlns="http://xamarin.com/schemas/2014/forms" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" | ||
xmlns:d="http://xamarin.com/schemas/2014/forms/design" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Title="Test 13670" xmlns:local="using:Xamarin.Forms.Controls" | ||
x:Class="Xamarin.Forms.Controls.Issues.Issue13670"> | ||
<StackLayout> | ||
<Label | ||
Padding="12" | ||
BackgroundColor="Black" | ||
TextColor="White" | ||
Text="Without setting the BackgroundColor of the SwipeView Content, the BackgroundColor of the SwipeView is used. "/> | ||
<CollectionView | ||
SelectionMode="Single" | ||
ItemsSource="{Binding Items}"> | ||
<CollectionView.ItemTemplate> | ||
<DataTemplate> | ||
<Grid Padding="5,10,5,10" BackgroundColor="#464646" RowSpacing="0" ColumnSpacing="2" RowDefinitions="Auto" ColumnDefinitions="10, *, 26, 26, 55, 55"> | ||
<SwipeView Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="4" BackgroundColor="#464646"> | ||
<SwipeView.LeftItems> | ||
<SwipeItems> | ||
<SwipeItemView IsVisible="{Binding CanShow}" BackgroundColor="#707070"> | ||
<Label Margin="20,0" VerticalTextAlignment="Center" HorizontalTextAlignment="Center" Text="A" TextColor="#FFFFFF" FontSize="22" /> | ||
</SwipeItemView> | ||
<SwipeItemView IsVisible="{Binding CanShow}" BackgroundColor="#707070"> | ||
<Label Margin="20,0" VerticalTextAlignment="Center" HorizontalTextAlignment="Center" Text="B" TextColor="#FFFFFF" FontSize="22" /> | ||
</SwipeItemView> | ||
</SwipeItems> | ||
</SwipeView.LeftItems> | ||
<Grid RowDefinitions="Auto, Auto" ColumnDefinitions="2, 10, *, 26, 26" RowSpacing="0" ColumnSpacing="2"> | ||
<BoxView Grid.Column="1" Grid.RowSpan="2" BackgroundColor="#325993" Margin="0,0,5,0" /> | ||
<Label VerticalTextAlignment="End" Grid.Row="0" Grid.Column="2" Text="{Binding Name}" LineBreakMode="TailTruncation" FontSize="Medium" TextColor="#FFFFFF" /> | ||
<Label VerticalOptions="Start" Grid.Row="1" Grid.Column="2" Text="..." TextColor="#95989A" /> | ||
<Label Grid.Row="0" Grid.Column="3" Grid.RowSpan="2" HorizontalOptions="End" IsVisible="False" WidthRequest="26" HeightRequest="26" HorizontalTextAlignment="Center" VerticalTextAlignment="Center" VerticalOptions="Center" /> | ||
<Label Grid.Row="0" Grid.Column="3" Grid.RowSpan="2" HorizontalOptions="End" IsVisible="False" WidthRequest="26" HeightRequest="26" HorizontalTextAlignment="Center" VerticalTextAlignment="Center" VerticalOptions="Center" /> | ||
<Label Grid.Row="0" Grid.Column="3" Grid.RowSpan="2" HorizontalOptions="End" IsVisible="False" WidthRequest="26" HeightRequest="26" HorizontalTextAlignment="Center" VerticalTextAlignment="Center" VerticalOptions="Center" /> | ||
<Label Grid.Row="0" Grid.Column="4" Grid.RowSpan="2" IsVisible="False" WidthRequest="26" HeightRequest="26" HorizontalTextAlignment="Center" VerticalTextAlignment="Center" VerticalOptions="Center" /> | ||
</Grid> | ||
</SwipeView> | ||
</Grid> | ||
</DataTemplate> | ||
</CollectionView.ItemTemplate> | ||
</CollectionView> | ||
</StackLayout> | ||
</local:TestContentPage> |
71 changes: 71 additions & 0 deletions
71
Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue13670.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
using System.Collections.ObjectModel; | ||
using System.ComponentModel; | ||
using System.Runtime.CompilerServices; | ||
using Xamarin.Forms.CustomAttributes; | ||
|
||
#if UITEST | ||
using Xamarin.UITest; | ||
using NUnit.Framework; | ||
using Xamarin.Forms.Core.UITests; | ||
#endif | ||
|
||
namespace Xamarin.Forms.Controls.Issues | ||
{ | ||
[Issue(IssueTracker.Github, 13670, | ||
"[Bug] [XF 5] SwipeView not rendering properly on iOS and Android when swiping", | ||
PlatformAffected.Android | PlatformAffected.iOS)] | ||
public partial class Issue13670 : TestContentPage | ||
{ | ||
public Issue13670() | ||
{ | ||
#if APP | ||
InitializeComponent(); | ||
|
||
Items = new ObservableCollection<Issue13670Model> | ||
{ | ||
new Issue13670Model { Name = "First" }, | ||
new Issue13670Model { Name = "Second" }, | ||
new Issue13670Model { Name = "Third" }, | ||
}; | ||
|
||
InitializeComponent(); | ||
|
||
ViewModel = this; | ||
#endif | ||
} | ||
|
||
protected override void Init() | ||
{ | ||
} | ||
|
||
public ObservableCollection<Issue13670Model> Items { get; private set; } | ||
|
||
public Issue13670 ViewModel | ||
{ | ||
get => BindingContext as Issue13670; | ||
set => BindingContext = value; | ||
} | ||
} | ||
|
||
public class Issue13670Model : INotifyPropertyChanged | ||
{ | ||
string _name; | ||
bool _canShow = true; | ||
|
||
public event PropertyChangedEventHandler PropertyChanged; | ||
|
||
public string Name { get => _name; set { _name = value; OnPropertyChanged(nameof(Name)); } } | ||
|
||
public bool CanShow { get => _canShow; set { _canShow = value; OnPropertyChanged(nameof(CanShow)); } } | ||
|
||
protected void OnPropertyChanged([CallerMemberName] string propertyName = "") | ||
{ | ||
var changed = PropertyChanged; | ||
|
||
if (changed == null) | ||
return; | ||
|
||
changed.Invoke(this, new PropertyChangedEventArgs(propertyName)); | ||
} | ||
} | ||
} |
62 changes: 62 additions & 0 deletions
62
Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue8282.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<controls:TestContentPage | ||
xmlns:controls="clr-namespace:Xamarin.Forms.Controls" | ||
xmlns="http://xamarin.com/schemas/2014/forms" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" | ||
xmlns:d="http://xamarin.com/schemas/2014/forms/design" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
x:Class="Xamarin.Forms.Controls.Issues.Issue8282" | ||
Title="Issue 8282"> | ||
<Grid | ||
RowSpacing="0"> | ||
<Grid.RowDefinitions> | ||
<RowDefinition Height="Auto" /> | ||
<RowDefinition Height="*" /> | ||
</Grid.RowDefinitions> | ||
<Label | ||
Padding="12" | ||
BackgroundColor="Black" | ||
TextColor="White" | ||
Text="Pull to Refresh. If the loading indicator appears above the CollectionView header, the test has passed. "/> | ||
<Grid | ||
Grid.Row="1"> | ||
<RefreshView | ||
BackgroundColor="Yellow" | ||
RefreshColor="Black" | ||
IsRefreshing="{Binding IsRefreshing}" | ||
Command="{Binding RefreshCommand}"> | ||
<CollectionView | ||
ItemsSource="{Binding Items}"> | ||
<CollectionView.Header> | ||
<Grid | ||
HeightRequest="200" | ||
BackgroundColor="#aadddddd"> | ||
<Label | ||
Text="Issue 8282" | ||
HorizontalOptions="Center" | ||
VerticalOptions="Center"/> | ||
</Grid> | ||
</CollectionView.Header> | ||
<CollectionView.ItemsLayout> | ||
<LinearItemsLayout | ||
Orientation="Vertical" | ||
ItemSpacing="5"/> | ||
</CollectionView.ItemsLayout> | ||
<CollectionView.ItemTemplate> | ||
<DataTemplate> | ||
<Grid | ||
HeightRequest="100" | ||
BackgroundColor="Beige"> | ||
<Label | ||
Text="{Binding Position}" | ||
HorizontalTextAlignment="Center" | ||
VerticalTextAlignment="Center"/> | ||
</Grid> | ||
</DataTemplate> | ||
</CollectionView.ItemTemplate> | ||
</CollectionView> | ||
</RefreshView> | ||
</Grid> | ||
</Grid> | ||
</controls:TestContentPage> |
Oops, something went wrong.