Exemple #1
0
        public static ScrollPolicy ToXwtScrollPolicy(this SWC.ScrollBarVisibility visibility)
        {
            switch (visibility)
            {
            case SWC.ScrollBarVisibility.Auto:
                return(ScrollPolicy.Automatic);

            case SWC.ScrollBarVisibility.Visible:
                return(ScrollPolicy.Always);

            case SWC.ScrollBarVisibility.Hidden:
                return(ScrollPolicy.Never);

            default:
                throw new NotSupportedException();
            }
        }
 private static TScrollViewer ScrollBarVisibilityV <TScrollViewer>(this TScrollViewer @this, SBV scrollBarVisibility)
     where TScrollViewer : ScrollViewer
 {
     @this.VerticalScrollBarVisibility = scrollBarVisibility;
     return(@this);
 }
 private static TScrollViewer ScrollBarVisibilityH <TScrollViewer>(this TScrollViewer @this, SBV scrollBarVisibility)
     where TScrollViewer : ScrollViewer
 {
     @this.HorizontalScrollBarVisibility = scrollBarVisibility;
     return(@this);
 }