Ejemplo n.º 1
0
 public void HarvestSetting(ref object setting)
 {
     foreach (Control ctrl in Items)
     {
         ISettingView settingView = ctrl as ISettingView;
         if (settingView != null)
         {
             settingView.HarvestSetting(ref setting);
         }
     }
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Mediator collect setting from all owned setting pages
        /// </summary>
        /// <param name="setting">The setting.</param>
        public void HarvestSetting(ref object setting)
        {
            if (_settingPagesMapping == null)
            {
                throw new Exception("Not initialized");
            }

            foreach (Control ctrl in _settingPagesMapping.Values)
            {
                ISettingView settingCtrl = ctrl as ISettingView;
                if (settingCtrl != null)
                {
                    settingCtrl.HarvestSetting(ref setting);
                }
            }
        }