This commit is contained in:
Kathy Ruffing 2012-01-27 12:44:11 +00:00
parent a87b931e55
commit d12adf6ace

View File

@ -672,6 +672,17 @@ namespace Volian.Controls.Library
btnInsTrans.Enabled = btnCMTransition.Enabled = btnInsRO.Enabled = btnCMRO.Enabled = false;
btnInsAftH.Enabled = btnInsBefH.Enabled = false;
btnInsHLS.Enabled = (!MyItemInfo.IsStepSection) ? false : true; // allow hls from step section
// if active item is a section and format has metasections, check that a hls can be added.
if (MyItemInfo.IsStepSection)
{
if (MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.UseMetaSections)
// The 'editable' data config must be set to allow new steps to be created.
{
SectionConfig sc = MyItemInfo.MyConfig as SectionConfig;
if (sc != null && MyItemInfo.Sections != null && MyItemInfo.Sections.Count > 0 && sc.SubSection_Edit != "Y")
btnInsHLS.Enabled = false;
}
}
if (btnInsHLS.Enabled)
{
btnInsHLS.SubItems.Clear();