Skip to content

Commit

Permalink
scrollbar visibility
Browse files Browse the repository at this point in the history
  • Loading branch information
Ieuan Walker authored and Ieuan Walker committed Sep 24, 2019
1 parent f4bb7ea commit 3644871
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Breadcrumb/Breadcrumb.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@
<ContentView x:Class="Breadcrumb.Breadcrumb"
xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Name="this"
IsVisible="False">
<ContentView.Content>
<ScrollView x:Name="BreadCrumbsScrollView"
HorizontalScrollBarVisibility="{Binding ScrollBarVisibility, Source={x:Reference this}}"
Orientation="Horizontal"
VerticalOptions="StartAndExpand">
<StackLayout x:Name="BreadCrumbContainer"
Expand Down
15 changes: 15 additions & 0 deletions Breadcrumb/Breadcrumb.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,21 @@ public partial class Breadcrumb : ContentView
{
#region Control properties

// Scrollbar Visibility
public static readonly BindableProperty ScrollBarVisibilityProperty = BindableProperty.Create(
nameof(ScrollBarVisibility),
typeof(ScrollBarVisibility),
typeof(Breadcrumb),
ScrollBarVisibility.Never,
defaultBindingMode: BindingMode.OneWay);

public ScrollBarVisibility ScrollBarVisibility
{
get => (ScrollBarVisibility)GetValue(ScrollBarVisibilityProperty);
set => SetValue(ScrollBarVisibilityProperty, value);
}


// Text Color
public static readonly BindableProperty TextColorProperty = BindableProperty.Create(
nameof(TextColor),
Expand Down

0 comments on commit 3644871

Please sign in to comment.