示例#1
0
        /// <summary>
        /// Obtains a control to edit a given property. Changes to the selection set
        /// cause this method to be called again (and passed a new 'context'),
        /// unless ICacheablePropertyControl is implemented on the control. For
        /// performance reasons, it is highly recommended that the control implement
        /// the ICacheablePropertyControl interface.</summary>
        /// <param name="context">Context for property editing control</param>
        /// <returns>Control to edit the given context</returns>
        public virtual Control GetEditingControl(PropertyEditorControlContext context)
        {
            var control = new BoundedIntControl(context, m_min, m_max);

            SkinService.ApplyActiveSkin(control);
            return(control);
        }
示例#2
0
        /// <summary>
        /// Obtains a control to edit a given property. Changes to the selection set
        /// cause this method to be called again (and passed a new 'context'),
        /// unless ICacheablePropertyControl is implemented on the control. For
        /// performance reasons, it is highly recommended that the control implement
        /// the ICacheablePropertyControl interface.</summary>
        /// <param name="context">Context for property editing control</param>
        /// <returns>Control to edit the given context</returns>
        public virtual Control GetEditingControl(PropertyEditorControlContext context)
        {
            var control = new BoundedIntControl(context, m_min, m_max);

            SkinService.ApplyActiveSkin(control);
            m_controlRefList.RemoveAll(item => !item.IsAlive);
            m_controlRefList.Add(new WeakReference(control));
            return(control);
        }
示例#3
0
 /// <summary>
 /// Obtains a control to edit a given property. Changes to the selection set
 /// cause this method to be called again (and passed a new 'context'),
 /// unless ICacheablePropertyControl is implemented on the control. For
 /// performance reasons, it is highly recommended that the control implement
 /// the ICacheablePropertyControl interface.</summary>
 /// <param name="context">Context for property editing control</param>
 /// <returns>Control to edit the given context</returns>
 public virtual Control GetEditingControl(PropertyEditorControlContext context)
 { 
     var control = new BoundedIntControl(context, m_min, m_max);          
     SkinService.ApplyActiveSkin(control);
     return control;
 }