public static int GetTvFocusedButtonHeight(this INavigationDrawer drawer) { if (s_defaultDrawerItemHeight > 0) { return(s_defaultDrawerItemHeight); } return(s_defaultDrawerItemHeight = ThemeConstants.Shell.Resources.DefaultDrawerItemHeight); }
public NavigationService(IActivityLifeTimeMonitor activityLifeTimeMonitor, ITransitionService transitionService, INavigationDrawer navigationDrawer, IParamsHolder paramsHolder, Dictionary <Type, Tuple <Type, int> > customMappings) { _activityLifeTimeMonitor = activityLifeTimeMonitor; _transitionService = transitionService; _navigationDrawer = navigationDrawer; _paramsHolder = paramsHolder; _customMappings = customMappings; InitPagesMappings(); }
protected override void OnElementChanged(ElementChangedEventArgs <Shell> e) { if (_native == null) { _native = CreateNavigationDrawer(); _navigationView = CreateNavigationView(); _native.NavigationView = _navigationView as ElmSharp.EvasObject; _native.Toggled += OnFlyoutIsPresentedChanged; SetNativeView(_native as ElmSharp.EvasObject); InitializeFlyout(); } base.OnElementChanged(e); }
protected override void OnElementChanged(ElementChangedEventArgs <Shell> e) { if (_drawer == null) { _drawer = CreateNavigationDrawer(); _navigationView = CreateNavigationView(); _drawer.NavigationView = _navigationView.NativeView; _drawer.Toggled += OnFlyoutIsPresentedChanged; SetNativeView(_drawer.TargetView); InitializeFlyout(); } base.OnElementChanged(e); UpdateFlyoutHeader(false); }
public ShellView(EvasObject parent) : base(parent) { NativeParent = parent; _navigationDrawer = CreateNavigationDrawer(); _navigationView = CreateNavigationView(); _navigationView.LayoutUpdated += OnNavigationViewLayoutUpdated; _navigationView.Content = _itemsView = CreateItemsView(); _navigationDrawer.NavigationView = _navigationView.TargetView; _navigationDrawer.Toggled += OnDrawerToggled; _navigationDrawer.TargetView.SetAlignment(-1.0, -1.0); _navigationDrawer.TargetView.SetWeight(1.0, 1.0); _navigationDrawer.TargetView.Show(); PackEnd(_navigationDrawer.TargetView); }
public ShellView(EvasObject parent) : base(parent) { PlatformParent = parent; _navigationDrawer = CreateNavigationDrawer(); _navigationView = CreateNavigationView(); _navigationView.LayoutUpdated += OnNavigationViewLayoutUpdated; _navigationView.Content = _itemsView = CreateItemsView(); _navigationDrawer.DrawerWidth = ThemeConstants.Shell.Resources.DefaultFlyoutItemWidth; _navigationDrawer.NavigationView = _navigationView.TargetView; _navigationDrawer.Toggled += OnDrawerToggled; _navigationDrawer.TargetView.SetAlignment(-1.0, -1.0); _navigationDrawer.TargetView.SetWeight(1.0, 1.0); _navigationDrawer.TargetView.Show(); Show(); PackEnd(_navigationDrawer.TargetView); }
public static double GetFlyoutCollapseRatio(this INavigationDrawer drawer) { return(0.05); }
public static double GetFlyoutRatio(this INavigationDrawer drawer, int width, int height) { return(s_navigationDrawerRatio = (width > height) ? 0.4 : 0.83); }
public static double GetTvDrawerCloseRatio(this INavigationDrawer drawer) { return(ThemeConstants.Shell.Resources.TV.DefaultDrawerCloseRatio); }
public static double GetTvDrawerRatio(this INavigationDrawer drawer, int width, int height) { return(s_navigationDrawerRatio = (width > height) ? ThemeConstants.Shell.Resources.TV.DefaultDrawerRatio : ThemeConstants.Shell.Resources.DefaultDrawerRatio); }