Exemple #1
0
        /// <summary>
        /// saves the new setting into configuration
        /// </summary>
        /// <param name="seconds">new refresh interval in seconds</param>
        private void SaveRecentChangesRefreshInterval(int seconds)
        {
            AnkhConfig cfg = Config;

            cfg.RecentChangesRefreshInterval = seconds;
            ConfigSvc.SaveConfig(cfg);
        }
        /// <summary>
        /// Saves the settings.
        /// </summary>
        public void SaveSettings()
        {
            // Load in case something changed in the mean time, other page/other VS instance
            ConfigSvc.LoadConfig();

            SaveSettingsCore();

            try
            {
                ConfigSvc.SaveConfig(Config);
            }
            catch (Exception ex)
            {
                IAnkhErrorHandler eh = Context.GetService <IAnkhErrorHandler>();

                if (eh != null && eh.IsEnabled(ex))
                {
                    eh.OnError(ex);
                    return;
                }

                throw;
            }
        }
 /// <summary>
 /// Loads the settings.
 /// </summary>
 public void LoadSettings()
 {
     ConfigSvc.LoadConfig();
     LoadSettingsCore();
 }
Exemple #4
0
 public void Init()
 {
     CommonTools.Log("CopyerFightSys Init Done");
     cacheSvc = CacheSvc.Instance;
     cfgSvc   = ConfigSvc.Instance;
 }
Exemple #5
0
 public void Init()
 {
     CommonTools.Log("TaskRewardSys Init Done.....");
     cacheSvc  = CacheSvc.Instance;
     configSvc = ConfigSvc.Instance;
 }
Exemple #6
0
 /// <summary>
 /// 初始化
 /// </summary>
 public void Init()
 {
     CommonTools.Log("GuideTaskSys Init Done");
     cacheSvc = CacheSvc.Instance;
     cfgSvc   = ConfigSvc.Instance;
 }