Exemple #1
0
        private void AdaptLayoytToScreenWidth()
        {
            simpleUI.AdjustToWidth(Width);       // this control has different narrow threashold
            simpleUIHeader.AdjustToWidth(Width); //iOS and Android always have -1 in page constructor (rather than actual size as in Mac/?WPF)

            var narrow = Width < narrowWidth;

            if (alreadyNarrow.HasValue)
            {
                if (alreadyNarrow.Value && narrow)
                {
                    return;
                }
                if (!alreadyNarrow.Value && !narrow)
                {
                    return;
                }
            }

            alreadyNarrow = narrow;

            simpleUI?.AdjustToWidth(Width);
            simpleUIHeader?.AdjustToWidth(Width);
            advancedUI?.AdaptLayoytToScreenWidth(narrow);
            testInProgress?.AdaptLayoytToScreenWidth(narrow);

            testSessionsPlaceholder?.AdaptLayoytToScreenWidth(narrow);
            MasterDetail.AsyncPreloadDetailsForSelectionGroup("testSessions");

            ViewModelContainer.NavigationViewModel.IsNarrowView = narrow;

            AdjustPopupsToWidth(narrow);
        }
Exemple #2
0
        private void AdaptLayoytToScreenWidth()
        {
            var narrow = Width < narrowWidth;

            if (alreadyNarrow.HasValue)
            {
                if (alreadyNarrow.Value && narrow)
                {
                    return;
                }
                if (!alreadyNarrow.Value && !narrow)
                {
                    return;
                }
            }

            alreadyNarrow = narrow;

            advancedUI?.AdaptLayoytToScreenWidth(narrow);
            testInProgress?.AdaptLayoytToScreenWidth(narrow);

            testSessionsPlaceholder?.AdaptLayoytToScreenWidth(narrow);
            MasterDetail.AsyncPreloadDetailsForSelectionGroup("testSessions");

            ViewModelContainer.NavigationViewModel.IsNarrowView = narrow;

            AdjustPopupsToWidth(narrow);
        }