Beispiel #1
0
        public void Reload()
        {
            var tabs   = TabablzControl.GetLoadedInstances().FirstOrDefault();
            var layout = LayoutAnalayzer.GetLayoutStructure(LAST_LAYOUT_NAME);

            Load(tabs, layout, _configurationService.ActiveConfiguration.Language);
        }
Beispiel #2
0
        public void Save()
        {
            LayoutStructure layoutStructure = LayoutAnalayzer.GetLayoutStructure(LAST_LAYOUT_NAME);

            Properties.Settings.Default.LastConfigName           = _configurationService.ActiveConfiguration.Name;
            _configurationService.ActiveConfiguration.LastLayout = SerializeStructure(layoutStructure);
            _configurationService.Save();
        }
Beispiel #3
0
        public void LoadAndSavePrevious(LayoutStructure layout)
        {
            LayoutStructure layoutStructure = LayoutAnalayzer.GetLayoutStructure(LAST_LAYOUT_NAME);

            _configurationService.ActiveConfiguration.LastLayout = SerializeStructure(layoutStructure);
            _configurationService.Save();

            var tabs = TabablzControl.GetLoadedInstances().FirstOrDefault();

            Load(tabs, layout, _configurationService.ActiveConfiguration.Language);
        }
Beispiel #4
0
        public void Handle(ConfigurationSwitched message)
        {
            if (!message.SwitchOnDeletion)
            {
                LayoutStructure layoutStructure = LayoutAnalayzer.GetLayoutStructure(LAST_LAYOUT_NAME);

                _configurationService.PreviousConfiguration.LastLayout = SerializeStructure(layoutStructure);
                _configurationService.Save();
            }
            var activeConfig = _configurationService.ActiveConfiguration;
            var tabs         = TabablzControl.GetLoadedInstances().FirstOrDefault();

            Load(tabs, activeConfig.PrimaryColor, activeConfig.AccentColor, activeConfig.DarkMode);
        }
Beispiel #5
0
        public string GetCurrentLayout(string name)
        {
            LayoutStructure layoutStructure = LayoutAnalayzer.GetLayoutStructure(name);

            return(SerializeStructure(layoutStructure));
        }