public void ChangeSettingsView(SettingsViewName name)
        {
            _viewModel.ChangeSettingsView(name);

            // Scroll into view
            //ListBoxSettings.ScrollIntoView(_viewModel.SelectedSettingsView);
        }
 public SettingsViewInfo(SettingsViewName name, Canvas icon, SettingsViewManager.Group group)
 {
     Name            = name;
     TranslatedName  = SettingsViewManager.TranslateName(name);
     Icon            = icon;
     Group           = group;
     TranslatedGroup = SettingsViewManager.TranslateGroup(group);
 }
Exemple #3
0
        public SettingsViewInfo(SettingsViewName name, UIElement uiElement, SettingsViewGroup group)
        {
            Name = name;
            var canvas = new Canvas();

            canvas.Children.Add(uiElement);
            Icon  = canvas;
            Group = group;
        }
        public SettingsViewInfo(SettingsViewName name, UIElement uiElement, SettingsViewManager.Group group)
        {
            Name           = name;
            TranslatedName = SettingsViewManager.TranslateName(name);
            var canvas = new Canvas();

            canvas.Children.Add(uiElement);
            Icon            = canvas;
            Group           = group;
            TranslatedGroup = SettingsViewManager.TranslateGroup(group);
        }
Exemple #5
0
        public static string TranslateName(SettingsViewName name)
        {
            switch (name)
            {
            case SettingsViewName.General:
                return(Resources.Localization.Strings.SettingsNameGeneral);

            case SettingsViewName.Window:
                return(Resources.Localization.Strings.SettingsNameWindow);

            case SettingsViewName.Appearance:
                return(Resources.Localization.Strings.SettingsNameAppearance);

            case SettingsViewName.ExcelExporter:
                return(Resources.Localization.Strings.SettingsNameExcelExporter);

            case SettingsViewName.Language:
                return(Resources.Localization.Strings.SettingsNameLanguage);

            case SettingsViewName.Update:
                return(Resources.Localization.Strings.SettingsNameUpdate);

            case SettingsViewName.Calculation:
                return(Resources.Localization.Strings.SettingsNameCalculation);

            case SettingsViewName.Printer:
                return(Resources.Localization.Strings.SettingsNamePrinter);

            case SettingsViewName.Settings:
                return(Resources.Localization.Strings.SettingsNameAppSettings);

            case SettingsViewName.ImportExport:
                return(Resources.Localization.Strings.SettingsNameImportExport);

            case SettingsViewName.Slicer:
                return(Resources.Localization.Strings.SettingsNameSlicer);

            case SettingsViewName.Gcode:
                return(Resources.Localization.Strings.SettingsNameGcode);

            case SettingsViewName.EULA:
                return(Resources.Localization.Strings.SettingsNameEULA);

            case SettingsViewName.EventLogger:
                return(Resources.Localization.Strings.SettingsEventLogger);

            case SettingsViewName.PrivacyPolicy:
                return(Resources.Localization.Strings.SettingsPrivacyPolicy);

            default:
                return(Resources.Localization.Strings.SettingsNameNotFound);
            }
        }
Exemple #6
0
 public EventSystemRedirectSettingsArgs(SettingsViewName name)
 {
     Setting = name;
     //Args = args;
 }
 public SettingsView(SettingsViewName settingsName)
 {
     InitializeComponent();
     _viewModel  = new SettingsViewModel(settingsName);
     DataContext = _viewModel;
 }
Exemple #8
0
 public SettingsViewInfo(SettingsViewName name, Canvas icon, SettingsViewGroup group)
 {
     Name  = name;
     Icon  = icon;
     Group = group;
 }
 /// <summary>
 /// Method to translate <see cref="SettingsViewName"/>.
 /// </summary>
 /// <param name="name"><see cref="SettingsViewName"/>.</param>
 /// <returns>Translated <see cref="SettingsViewName"/>.</returns>
 public string Translate(SettingsViewName name)
 {
     return(Translate(name.ToString()));
 }
Exemple #10
0
 public static void RedirectToSettings(SettingsViewName name)
 {
     RedirectToSettingsEvent?.Invoke(typeof(string), new EventSystemRedirectSettingsArgs(name));
 }