diff --git a/Demo/Controls/Examples/BackButton.xaml b/Demo/Controls/Examples/BackButton.xaml index f98bae2..9e106b6 100644 --- a/Demo/Controls/Examples/BackButton.xaml +++ b/Demo/Controls/Examples/BackButton.xaml @@ -23,4 +23,4 @@ - + \ No newline at end of file diff --git a/Demo/Controls/Examples/CustomButton.xaml b/Demo/Controls/Examples/CustomButton.xaml index b8a71be..601a890 100644 --- a/Demo/Controls/Examples/CustomButton.xaml +++ b/Demo/Controls/Examples/CustomButton.xaml @@ -31,4 +31,4 @@ - + \ No newline at end of file diff --git a/Demo/Controls/Examples/CustomButton.xaml.cs b/Demo/Controls/Examples/CustomButton.xaml.cs index e36bf48..6a4af65 100644 --- a/Demo/Controls/Examples/CustomButton.xaml.cs +++ b/Demo/Controls/Examples/CustomButton.xaml.cs @@ -3,6 +3,7 @@ namespace App.Controls.Examples; public partial class CustomButton : ContentView { public static readonly BindableProperty TextProperty = BindableProperty.Create(nameof(Text), typeof(string), typeof(CustomButton), string.Empty); + public string Text { get => (string)GetValue(TextProperty); @@ -10,6 +11,7 @@ public string Text } public event EventHandler? Clicked; + public CustomButton() { InitializeComponent(); diff --git a/Demo/Controls/Examples/Examle1.xaml b/Demo/Controls/Examples/Examle1.xaml index 55ce77a..5568881 100644 --- a/Demo/Controls/Examples/Examle1.xaml +++ b/Demo/Controls/Examples/Examle1.xaml @@ -22,4 +22,4 @@ TextColor="#313131" VerticalTextAlignment="Center" /> - + \ No newline at end of file diff --git a/Demo/Controls/Examples/Example2.xaml b/Demo/Controls/Examples/Example2.xaml index 43a96ce..84c4224 100644 --- a/Demo/Controls/Examples/Example2.xaml +++ b/Demo/Controls/Examples/Example2.xaml @@ -84,4 +84,4 @@ - + \ No newline at end of file diff --git a/Demo/Controls/Examples/Example3.xaml b/Demo/Controls/Examples/Example3.xaml index 011fcf3..f62fded 100644 --- a/Demo/Controls/Examples/Example3.xaml +++ b/Demo/Controls/Examples/Example3.xaml @@ -44,4 +44,4 @@ TextColor="#9FE9C8" /> - + \ No newline at end of file diff --git a/Demo/Controls/Examples/Example4.xaml b/Demo/Controls/Examples/Example4.xaml index 8d7c051..23625a5 100644 --- a/Demo/Controls/Examples/Example4.xaml +++ b/Demo/Controls/Examples/Example4.xaml @@ -41,4 +41,4 @@ - + \ No newline at end of file diff --git a/Demo/Controls/Examples/Example5.xaml b/Demo/Controls/Examples/Example5.xaml index fcc061f..6696710 100644 --- a/Demo/Controls/Examples/Example5.xaml +++ b/Demo/Controls/Examples/Example5.xaml @@ -39,4 +39,4 @@ - + \ No newline at end of file diff --git a/Demo/Controls/Examples/Example6.xaml b/Demo/Controls/Examples/Example6.xaml index ee81055..0fd1937 100644 --- a/Demo/Controls/Examples/Example6.xaml +++ b/Demo/Controls/Examples/Example6.xaml @@ -5,7 +5,7 @@ xmlns:stateButton="clr-namespace:IeuanWalker.Maui.StateButton;assembly=IeuanWalker.Maui.StateButton"> - - + \ No newline at end of file diff --git a/Demo/Controls/Examples/Example6.xaml.cs b/Demo/Controls/Examples/Example6.xaml.cs index 863e0cb..ff6ada0 100644 --- a/Demo/Controls/Examples/Example6.xaml.cs +++ b/Demo/Controls/Examples/Example6.xaml.cs @@ -5,12 +5,15 @@ namespace App.Controls.Examples; public partial class Example6 : ContentView { public static readonly BindableProperty TextProperty = BindableProperty.Create(nameof(Text), typeof(string), typeof(CustomButton), string.Empty); + public string Text { get => (string)GetValue(TextProperty); set => SetValue(TextProperty, value); } + public static readonly BindableProperty AccessibilityHintProperty = BindableProperty.Create(nameof(AccessibilityHint), typeof(string), typeof(CustomButton), string.Empty); + public string AccessibilityHint { get => (string)GetValue(AccessibilityHintProperty); @@ -102,7 +105,9 @@ public object ReleasedCommandParameter } public event EventHandler? Clicked; + public event EventHandler? Pressed; + public event EventHandler? Released; public Example6() diff --git a/Demo/Controls/Examples/Example7.xaml b/Demo/Controls/Examples/Example7.xaml index 0f56a98..0d16f2c 100644 --- a/Demo/Controls/Examples/Example7.xaml +++ b/Demo/Controls/Examples/Example7.xaml @@ -28,4 +28,4 @@ - + \ No newline at end of file diff --git a/Demo/Controls/Examples/Example7.xaml.cs b/Demo/Controls/Examples/Example7.xaml.cs index c0734b9..472c814 100644 --- a/Demo/Controls/Examples/Example7.xaml.cs +++ b/Demo/Controls/Examples/Example7.xaml.cs @@ -3,6 +3,7 @@ namespace App.Controls.Examples; public partial class Example7 : ContentView { public static readonly BindableProperty IconProperty = BindableProperty.Create(nameof(Icon), typeof(string), typeof(CustomButton), string.Empty); + public string Icon { get => (string)GetValue(IconProperty); diff --git a/Demo/Controls/Examples/Example8.xaml b/Demo/Controls/Examples/Example8.xaml index 3050e76..6ba82a8 100644 --- a/Demo/Controls/Examples/Example8.xaml +++ b/Demo/Controls/Examples/Example8.xaml @@ -35,4 +35,4 @@ TextColor="White" VerticalTextAlignment="Center" /> - + \ No newline at end of file diff --git a/Demo/MainPage.xaml.cs b/Demo/MainPage.xaml.cs index 8b0c2c7..b193ef0 100644 --- a/Demo/MainPage.xaml.cs +++ b/Demo/MainPage.xaml.cs @@ -13,10 +13,12 @@ async void ExampleBtn_Clicked(object sender, EventArgs e) { await Navigation.PushAsync(new ExamplePage()); } + async void EventCommandBtn_Clicked(object sender, EventArgs e) { await Navigation.PushAsync(new EventCommandPage()); } + async void BtnNotInScrollView_Clicked(object sender, EventArgs e) { await Navigation.PushAsync(new ButtonNotInScrollViewPage()); diff --git a/Scr/Handler/IStateButtonHandler.cs b/Scr/Handler/IStateButtonHandler.cs index 3281be8..95cce0f 100644 --- a/Scr/Handler/IStateButtonHandler.cs +++ b/Scr/Handler/IStateButtonHandler.cs @@ -1,6 +1,7 @@ using Microsoft.Maui.Handlers; namespace IeuanWalker.Maui.StateButton.Handler; + public interface IStateButtonHandler : IBorderHandler { } \ No newline at end of file diff --git a/Scr/Handler/StateButtonHandler.cs b/Scr/Handler/StateButtonHandler.cs index c237e08..6052a2e 100644 --- a/Scr/Handler/StateButtonHandler.cs +++ b/Scr/Handler/StateButtonHandler.cs @@ -1,5 +1,4 @@ -using IeuanWalker.Maui.StateButton.Handler; -using Microsoft.Maui.Handlers; +using Microsoft.Maui.Handlers; namespace IeuanWalker.Maui.StateButton.Handler; diff --git a/Scr/Platform/CustomContentViewGroup.Android.cs b/Scr/Platform/CustomContentViewGroup.Android.cs index c729d35..8b624ae 100644 --- a/Scr/Platform/CustomContentViewGroup.Android.cs +++ b/Scr/Platform/CustomContentViewGroup.Android.cs @@ -1,7 +1,6 @@ using Android.Content; using Android.Runtime; using Android.Views; -using Android.Views.Accessibility; using Java.Lang; using Microsoft.Maui.Platform; using String = Java.Lang.String;