/// ----------------------------------------------------------------------------- /// <summary> /// Creates a DNNMultiStateBoxColumnTemplate /// </summary> /// <returns>A DNNMultiStateBoxColumnTemplate</returns> /// ----------------------------------------------------------------------------- private DNNMultiStateBoxColumnTemplate CreateTemplate(ListItemType type) { bool isDesignMode = false; if (HttpContext.Current == null) { isDesignMode = true; } var template = new DNNMultiStateBoxColumnTemplate(type); if (type != ListItemType.Header) { template.AutoPostBack = AutoPostBack; } template.DataField = DataField; template.Enabled = Enabled; template.EnabledField = EnabledField; template.ImagePath = ImagePath; foreach (DNNMultiState objState in States) { template.States.Add(objState); } template.SelectedStateKey = SelectedStateKey; if (type == ListItemType.Header) { template.Text = HeaderText; template.AutoPostBack = true; } template.DesignMode = isDesignMode; return(template); }
/// ----------------------------------------------------------------------------- /// <summary> /// Creates a DNNMultiStateBoxColumnTemplate /// </summary> /// <returns>A DNNMultiStateBoxColumnTemplate</returns> /// <history> /// [cnurse] 02/16/2006 created /// </history> /// ----------------------------------------------------------------------------- private DNNMultiStateBoxColumnTemplate CreateTemplate(ListItemType type) { bool isDesignMode = false; if (HttpContext.Current == null) { isDesignMode = true; } var template = new DNNMultiStateBoxColumnTemplate(type); if (type != ListItemType.Header) { template.AutoPostBack = AutoPostBack; } template.DataField = DataField; template.Enabled = Enabled; template.EnabledField = EnabledField; template.ImagePath = ImagePath; foreach (DNNMultiState objState in States) { template.States.Add(objState); } template.SelectedStateKey = SelectedStateKey; if (type == ListItemType.Header) { template.Text = HeaderText; template.AutoPostBack = true; } template.DesignMode = isDesignMode; return template; }