function [widgets, currRow] = getSharedWidgets(this, src, enableWidget, currRow, type, tag)
%GETSHAREDWIDGETS   Get the shared tabDialogSchema.

%   Copyright 2008-2023 The MathWorks, Inc.

% DataType of src is 'hdlcoderprops.CLI'

switch type
    case 'main'
        [widgets, currRow] = buildMain(this, src, enableWidget, currRow, tag);
    case 'general'
        [widgets, currRow] = buildGeneralTab(this, src, enableWidget, currRow, tag);
    case 'ports'
        [widgets, currRow] = buildPortsTab(this, src, enableWidget, currRow, tag);
    case 'advanced'
        [widgets, currRow] = buildAdvancedTab(this, src, enableWidget, currRow, tag);
end

%--------------------------------------------------------------------------
function [widgets, currRow] = buildMain(this, src, enableWidget, currRow, tag)
% Widgets on the "General" tab 

% Reset Type label & combobox
rtype_cbOP = 'ResetType'; 
rtype_lbl.Type = 'text';
rtype_lbl.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingsResetType');
rtype_lbl.RowSpan = [currRow currRow];
rtype_lbl.ColSpan = [1 1];

rtype_cb.Type = 'combobox';
rtype_cb.Tag = [tag rtype_cbOP];
rtype_lbl.Buddy = rtype_cb.Tag;
rtype_cb.RowSpan = [currRow currRow];
rtype_cb.ColSpan = [2 2];
rtype_cb.Source = src;
rtype_cb.Mode = true;
rtype_cb.Enabled = enableWidget;
a                       = hdlcoderprops.hdlcoderpropsDataType.HDLResetTypes;
cbEntries               = a.Strings;
rtype_cb.Entries        = getTranslatedStringcell('HDLShared:fdhdldialog',cbEntries);
defaultindx = find(strcmpi(cbEntries,src.(rtype_cbOP)));
if ~isempty(defaultindx)
    rtype_cb.Value = defaultindx - 1;
end
rtype_cb.ObjectMethod = 'selectComboboxEntryCLI';
rtype_cb.MethodArgs  = {'%value', rtype_cbOP, cbEntries, src};
rtype_cb.ArgDataTypes = {'mxArray', 'string', 'mxArray', 'mxArray'};


% Reset Asserted Level label & combobox
ralvlOP = 'ResetAssertedLevel';
ralvl_lbl.Type = 'text';
ralvl_lbl.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingsResetAssertedLevel');
ralvl_lbl.RowSpan = [currRow currRow];
ralvl_lbl.ColSpan = [3 3];

ralvl_cb.Type = 'combobox';
ralvl_cb.Tag = [tag ralvlOP];
ralvl_lbl.Buddy = ralvl_cb.Tag;
ralvl_cb.RowSpan = [currRow currRow];
ralvl_cb.ColSpan = [4 4];
ralvl_cb.Source = this;
ralvl_cb.Mode = true;
ralvl_cb.Enabled = enableWidget;
a                       = hdlcoderprops.hdlcoderpropsDataType.HDLActiveLevels;
cbEntries               = a.Strings;
ralvl_cb.Entries        = getTranslatedStringcell('HDLShared:fdhdldialog',cbEntries);
defaultindx = find(strcmpi(cbEntries,src.(ralvlOP)));
if ~isempty(defaultindx)
    ralvl_cb.Value = defaultindx - 1;
end
ralvl_cb.ObjectMethod = 'selectComboboxEntryCLI';
ralvl_cb.MethodArgs  = {'%value', ralvlOP, cbEntries, src};
ralvl_cb.ArgDataTypes = {'mxArray', 'string', 'mxArray', 'mxArray'};

currRow = currRow+1;
% Clock Input Port label & edit box
clkIPOP = 'ClockInputPort';
clkIP_lbl.Type = 'text';
clkIP_lbl.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingsClockInputPort');
clkIP_lbl.RowSpan = [currRow currRow];
clkIP_lbl.ColSpan = [1 1];

clkIP_cb.Type = 'edit';
clkIP_cb.ObjectProperty = clkIPOP;
clkIP_cb.Tag = [tag clkIP_cb.ObjectProperty];
clkIP_lbl.Buddy = clkIP_cb.Tag;
clkIP_cb.RowSpan = [currRow currRow];
clkIP_cb.ColSpan = [2 2];
clkIP_cb.Source = src;
clkIP_cb.Mode = true;
clkIP_cb.Enabled = enableWidget;
 
% Clock Enable Input Port label & edit box
clkEPOP = 'ClockEnableInputPort';
clkEP_lbl.Type = 'text';
clkEP_lbl.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingsClockEnableInputPort');
clkEP_lbl.RowSpan = [currRow currRow];
clkEP_lbl.ColSpan = [3 3];

clkEP_cb.Type = 'edit';
clkEP_cb.ObjectProperty = clkEPOP;
clkEP_cb.Tag = [tag clkEP_cb.ObjectProperty];
clkEP_lbl.Buddy = clkEP_cb.Tag;
clkEP_cb.RowSpan = [currRow currRow];
clkEP_cb.ColSpan = [4 4];
clkEP_cb.Source = src;
clkEP_cb.Mode = true;
clkEP_cb.Enabled = enableWidget;

currRow = currRow+1;
% Reset Input Port label & edit box
rstIPOP = 'ResetInputPort';
rstIP_lbl.Type = 'text';
rstIP_lbl.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingsResetInputPort');
rstIP_lbl.RowSpan = [currRow currRow];
rstIP_lbl.ColSpan = [1 1];

rstIP_eb.Type = 'edit';
rstIP_eb.ObjectProperty = rstIPOP;
rstIP_eb.Tag = [tag rstIP_eb.ObjectProperty];
rstIP_lbl.Buddy = rstIP_eb.Tag;
rstIP_eb.RowSpan = [currRow currRow];
rstIP_eb.ColSpan = [2 2];
rstIP_eb.Source = src;
rstIP_eb.Mode = true;
rstIP_eb.Enabled = enableWidget;

widgets = {rtype_lbl,rtype_cb,ralvl_lbl,ralvl_cb,clkIP_lbl,clkIP_cb,clkEP_lbl,clkEP_cb,rstIP_lbl,rstIP_eb};

%--------------------------------------------------------------------------
function [widgets, currRow] = buildGeneralTab(this, hObjCLI, enableWidget, currRow, tag)
% Widgets on the "General" tab 

VerilogEnabled = strcmpi(hObjCLI.TargetLanguage, 'verilog');
tag = [tag, 'General_'];

CommentOP = 'UserComment';
lblComment.Type = 'text';
lblComment.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingUserComment');
lblComment.RowSpan = [currRow currRow];
lblComment.ColSpan = [1 1];

txtComment.Type = 'edit';
txtComment.ObjectProperty = CommentOP;
txtComment.Tag = [tag txtComment.ObjectProperty];
lblComment.Buddy = txtComment.Tag;
txtComment.RowSpan = [currRow currRow];
txtComment.ColSpan = [2 4];
txtComment.Source = hObjCLI;
txtComment.Mode = true;
txtComment.Enabled = enableWidget;

currRow = currRow+1;
VerilogFileExtOP = 'VerilogFileExtension';
lblVerilogFileExt.Type = 'text';
lblVerilogFileExt.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingVerilogFileExtension');
lblVerilogFileExt.RowSpan = [currRow currRow];
lblVerilogFileExt.ColSpan = [1 1];

txtVerilogFileExt.Type = 'edit';
txtVerilogFileExt.ObjectProperty = VerilogFileExtOP;
txtVerilogFileExt.Tag = [tag txtVerilogFileExt.ObjectProperty];
lblVerilogFileExt.Buddy = txtVerilogFileExt.Tag;
txtVerilogFileExt.RowSpan = [currRow currRow];
txtVerilogFileExt.ColSpan = [2 2];
txtVerilogFileExt.Source = hObjCLI;
txtVerilogFileExt.Enabled = VerilogEnabled & enableWidget;
txtVerilogFileExt.Mode = true;

VHDLFileExtOP = 'VHDLFileExtension';
lblVHDLFileExt.Type = 'text';
lblVHDLFileExt.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingVHDLFileExtension');
lblVHDLFileExt.RowSpan = [currRow currRow];
lblVHDLFileExt.ColSpan = [3 3];

txtVHDLFileExt.Type = 'edit';
txtVHDLFileExt.ObjectProperty = VHDLFileExtOP;
txtVHDLFileExt.Tag = [tag txtVHDLFileExt.ObjectProperty];
lblVHDLFileExt.Buddy = txtVHDLFileExt.Tag;
txtVHDLFileExt.RowSpan = [currRow currRow];
txtVHDLFileExt.ColSpan = [4 4];
txtVHDLFileExt.Source = hObjCLI;
txtVHDLFileExt.Mode = true;
txtVHDLFileExt.Enabled = ~VerilogEnabled & enableWidget;

currRow = currRow+1;

EntityConfPostfixOP = 'EntityConflictPostfix';
lblEntityConfPostfix.Type = 'text';
lblEntityConfPostfix.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingEntityConflictPostfix');
lblEntityConfPostfix.RowSpan = [currRow currRow];
lblEntityConfPostfix.ColSpan = [1 1];

txtEntityConfPostfix.Type = 'edit';
txtEntityConfPostfix.ObjectProperty = EntityConfPostfixOP;
txtEntityConfPostfix.Tag = [tag txtEntityConfPostfix.ObjectProperty];
lblEntityConfPostfix.Buddy = txtEntityConfPostfix.Tag;
txtEntityConfPostfix.RowSpan = [currRow currRow];
txtEntityConfPostfix.ColSpan = [2 2];
txtEntityConfPostfix.Source = hObjCLI;
txtEntityConfPostfix.Mode = true;
txtEntityConfPostfix.Enabled = enableWidget;

PackagePostfixOP = 'PackagePostfix';
lblPackagePostfix.Type = 'text';
lblPackagePostfix.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingPackagePostfix');
lblPackagePostfix.RowSpan = [currRow currRow];
lblPackagePostfix.ColSpan = [3 3];

txtPackagePostfix.Type = 'edit';
txtPackagePostfix.ObjectProperty = PackagePostfixOP;
txtPackagePostfix.Tag = [tag txtPackagePostfix.ObjectProperty];
lblPackagePostfix.Buddy = txtPackagePostfix.Tag;
txtPackagePostfix.RowSpan = [currRow currRow];
txtPackagePostfix.ColSpan = [4 4];
txtPackagePostfix.Source = hObjCLI;
txtPackagePostfix.Mode = true;

if enableWidget 
    if VerilogEnabled
        if strcmpi(hObjCLI.MultifileTestBench, 'on')
            txtPackagePostfix.Enabled = true;
        else
            txtPackagePostfix.Enabled = false;
        end
    else
        txtPackagePostfix.Enabled = true;
    end
else
    txtPackagePostfix.Enabled = false;
end

currRow = currRow+1;

ResWordPostfixOP = 'ReservedWordPostfix';
lblResWordPostfix.Type = 'text';
lblResWordPostfix.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingReservedWordPostfix');
lblResWordPostfix.RowSpan = [currRow currRow];
lblResWordPostfix.ColSpan = [1 1];

txtResWordPostfix.Type = 'edit';
txtResWordPostfix.ObjectProperty = ResWordPostfixOP;
txtResWordPostfix.Tag = [tag txtResWordPostfix.ObjectProperty];
lblResWordPostfix.Buddy = txtResWordPostfix.Tag;
txtResWordPostfix.RowSpan = [currRow currRow];
txtResWordPostfix.ColSpan = [2 2];
txtResWordPostfix.Mode = true;
txtResWordPostfix.Source = hObjCLI;
txtResWordPostfix.Enabled = enableWidget;

SplitEntFilePostfixOP = 'SplitEntityFilePostfix';
lblSplitEntFilePostfix.Type = 'text';
lblSplitEntFilePostfix.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingSplitEntityFilePostfix');
lblSplitEntFilePostfix.RowSpan = [currRow currRow];
lblSplitEntFilePostfix.ColSpan = [3 3];

txtSplitEntFilePostfix.Type = 'edit';
txtSplitEntFilePostfix.Tag = [tag SplitEntFilePostfixOP];
lblSplitEntFilePostfix.Buddy = txtSplitEntFilePostfix.Tag;
txtSplitEntFilePostfix.ObjectProperty = SplitEntFilePostfixOP;
txtSplitEntFilePostfix.RowSpan = [currRow currRow];
txtSplitEntFilePostfix.ColSpan = [4 4];
txtSplitEntFilePostfix.Enabled = strcmpi(hObjCLI.SplitEntityArch, 'on') & enableWidget;
txtSplitEntFilePostfix.Source = hObjCLI;
txtSplitEntFilePostfix.Mode = true;

currRow = currRow+1;

ClockedProcessPostfixOP = 'ClockProcessPostfix';
lblClockedProcessPostfix.Type = 'text';
lblClockedProcessPostfix.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingClockProcessPostfix');
lblClockedProcessPostfix.RowSpan = [currRow currRow];
lblClockedProcessPostfix.ColSpan = [1 1];

txtClockedProcessPostfix.Type = 'edit';
txtClockedProcessPostfix.Tag = [tag,ClockedProcessPostfixOP];
lblClockedProcessPostfix.Buddy = txtClockedProcessPostfix.Tag;
txtClockedProcessPostfix.ObjectProperty = ClockedProcessPostfixOP;
txtClockedProcessPostfix.RowSpan = [currRow currRow];
txtClockedProcessPostfix.ColSpan = [2 2];
txtClockedProcessPostfix.Source = hObjCLI;
txtClockedProcessPostfix.Mode = true;
txtClockedProcessPostfix.Enabled = enableWidget;

SplitArchFilePostfixOP = 'SplitArchFilePostfix';
lblSplitArchFilePostfix.Type = 'text';
lblSplitArchFilePostfix.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingSplitArchFilePostfix');
lblSplitArchFilePostfix.RowSpan = [currRow currRow];
lblSplitArchFilePostfix.ColSpan = [3 3];

txtSplitArchFilePostfix.Type = 'edit';
txtSplitArchFilePostfix.ObjectProperty = SplitArchFilePostfixOP;
txtSplitArchFilePostfix.Tag = [tag,txtSplitArchFilePostfix.ObjectProperty];
lblSplitArchFilePostfix.Buddy = txtSplitArchFilePostfix.Tag;
txtSplitArchFilePostfix.RowSpan = [currRow currRow];
txtSplitArchFilePostfix.ColSpan = [4 4];
txtSplitArchFilePostfix.Enabled = strcmpi(hObjCLI.SplitEntityArch, 'on') & enableWidget;
txtSplitArchFilePostfix.Source = hObjCLI;
txtSplitArchFilePostfix.Mode = true;



currRow = currRow+1;
% ComplexRealPostfix
realPostfixOP = 'ComplexRealPostfix';
realPostfix_lbl.Type = 'text';
realPostfix_lbl.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingComplexRealPostfix');
realPostfix_lbl.Tag = [tag,realPostfixOP,'_lbl'];
realPostfix_lbl.RowSpan = [currRow currRow];
realPostfix_lbl.ColSpan = [1 1];

realPostfix_eb.Type = 'edit';
realPostfix_eb.ObjectProperty = realPostfixOP;
realPostfix_eb.Tag = [tag realPostfix_eb.ObjectProperty];
realPostfix_lbl.Buddy = realPostfix_eb.Tag;
realPostfix_eb.RowSpan = [currRow currRow];
realPostfix_eb.ColSpan = [2 2];
realPostfix_eb.Source = hObjCLI;
realPostfix_eb.Mode = true;
realPostfix_eb.Enabled = enableWidget;

chkSplitEntityOP = 'SplitEntityArch';
chkSplitEntity.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingSplitEntityArch');
chkSplitEntity.Tag = [tag chkSplitEntityOP];
chkSplitEntity.Type = 'checkbox';
chkSplitEntity.RowSpan = [currRow currRow];
chkSplitEntity.ColSpan = [3 4];
chkSplitEntity.Mode = true;
chkSplitEntity.DialogRefresh = true;
chkSplitEntity.Source = this;
chkSplitEntity.Enabled = ~VerilogEnabled & enableWidget;
chkSplitEntity.ObjectMethod = 'setCheckBox';
chkSplitEntity.Value        = strcmpi(hObjCLI.(chkSplitEntityOP), 'on');
chkSplitEntity.MethodArgs   = {'%value', chkSplitEntityOP, hObjCLI};
chkSplitEntity.ArgDataTypes = {'mxArray', 'string', 'mxArray'};

currRow = currRow+1;

imagPostfixOP = 'ComplexImagPostfix';
imagPostfix_lbl.Type = 'text';
imagPostfix_lbl.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingComplexImagPostfix');
imagPostfix_lbl.Tag = [tag,imagPostfixOP,'_lbl'];
imagPostfix_lbl.RowSpan = [currRow currRow];
imagPostfix_lbl.ColSpan = [1 1];

imagPostfix_eb.Type = 'edit';
imagPostfix_eb.ObjectProperty = imagPostfixOP;
imagPostfix_eb.Tag = [tag imagPostfix_eb.ObjectProperty];
imagPostfix_lbl.Buddy = imagPostfix_eb.Tag;
imagPostfix_eb.RowSpan = [currRow currRow];
imagPostfix_eb.ColSpan = [2 2];
imagPostfix_eb.Source = hObjCLI;
imagPostfix_eb.Mode = true;
imagPostfix_eb.Enabled = enableWidget;

widgets = {lblComment,...
txtComment,...
lblVerilogFileExt,...
txtVerilogFileExt,...
lblVHDLFileExt,...
txtVHDLFileExt,...
lblEntityConfPostfix,...
txtEntityConfPostfix,...
lblPackagePostfix,...
txtPackagePostfix,...
lblResWordPostfix,...
txtResWordPostfix,...
chkSplitEntity,...
lblSplitEntFilePostfix,...
txtSplitEntFilePostfix,...
lblSplitArchFilePostfix,...
txtSplitArchFilePostfix,...
lblClockedProcessPostfix,...
txtClockedProcessPostfix, ...
realPostfix_lbl, ...
realPostfix_eb, ...
imagPostfix_lbl, ...
imagPostfix_eb ...
};


%--------------------------------------------------------------------------
function [widgets, currRow] = buildPortsTab(this, hObjCLI, enableWidget, currRow, tag)
% Widgets on the "Ports" tab 

VerilogEnabled = strcmpi(hObjCLI.TargetLanguage, 'verilog');
tag = [tag, 'Ports_'];

InputDataTypeOP = 'InputType';
lblInputDataType.Type = 'text';
lblInputDataType.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingInputType');
lblInputDataType.RowSpan = [currRow currRow];
lblInputDataType.ColSpan = [1 1];

cmbInputDataType.Type = 'combobox';
cmbInputDataType.Tag = [tag,InputDataTypeOP];
lblInputDataType.Buddy = cmbInputDataType.Tag;
if VerilogEnabled == true
    % g627257 - always source CLI
    cmbInputDataType.Entries = {'wire'};
else    
    cmbInputDataType.Source = this;
    cmbInputDataType.ObjectProperty = InputDataTypeOP;
    a                       = hdlcoderprops.hdlcoderpropsDataType.HDLInputTypes;
    cbEntries               = a.Strings;
    cmbInputDataType.Entries  = getTranslatedStringcell('HDLShared:fdhdldialog',cbEntries);
    defaultindx = find(strcmpi(cbEntries,hObjCLI.(InputDataTypeOP)));
    if ~isempty(defaultindx)
        cmbInputDataType.Value = defaultindx - 1;
    end
    cmbInputDataType.ObjectMethod = 'selectComboboxEntryCLI';
    cmbInputDataType.MethodArgs  = {'%value', InputDataTypeOP, cbEntries, hObjCLI};
    cmbInputDataType.ArgDataTypes = {'mxArray', 'string', 'mxArray', 'mxArray'};
end
cmbInputDataType.RowSpan = [currRow currRow];
cmbInputDataType.ColSpan = [2 2];
cmbInputDataType.Enabled = ~VerilogEnabled & enableWidget;
cmbInputDataType.Mode = true;

currRow = currRow+1;
OutputDataTypeOP =  'OutputType';
lblOutputDataType.Type = 'text';
lblOutputDataType.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingOutputType');
lblOutputDataType.RowSpan = [currRow currRow];
lblOutputDataType.ColSpan = [1 1];

cmbOutputDataType.Type = 'combobox';
cmbOutputDataType.Tag = [tag,OutputDataTypeOP];
lblOutputDataType.Buddy = cmbOutputDataType.Tag;
if VerilogEnabled == true
    % g627257 - always source CLI
    cmbOutputDataType.Entries = {'wire'};
else
    cmbOutputDataType.Source = this;
    cmbOutputDataType.ObjectProperty = OutputDataTypeOP;
    a                       = hdlcoderprops.hdlcoderpropsDataType.HDLOutputTypes;
    cbEntries               = a.Strings;
    cmbOutputDataType.Entries  = getTranslatedStringcell('HDLShared:fdhdldialog',cbEntries);
    defaultindx = find(strcmpi(cbEntries,hObjCLI.(OutputDataTypeOP)));
    if ~isempty(defaultindx)
        cmbOutputDataType.Value = defaultindx - 1;
    end
    cmbOutputDataType.ObjectMethod = 'selectComboboxEntryCLI';
    cmbOutputDataType.MethodArgs  = {'%value', OutputDataTypeOP, cbEntries, hObjCLI};
    cmbOutputDataType.ArgDataTypes = {'mxArray', 'string', 'mxArray', 'mxArray'};
end
cmbOutputDataType.RowSpan = [currRow currRow];
cmbOutputDataType.ColSpan = [2 2];
cmbOutputDataType.Enabled = ~VerilogEnabled & enableWidget;
cmbOutputDataType.Mode = true;

currRow = currRow+1;

ClockEnableOutputPortOP = 'ClockEnableOutputPort';
lblClockEnableOutputPort.Type = 'text';
lblClockEnableOutputPort.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingClockEnableOutputPort');
lblClockEnableOutputPort.RowSpan = [currRow currRow];
lblClockEnableOutputPort.ColSpan = [1 1];

edClockEnableOutputPort.Type = 'edit';
edClockEnableOutputPort.Tag = [tag,ClockEnableOutputPortOP];
lblClockEnableOutputPort.Buddy = edClockEnableOutputPort.Tag;
edClockEnableOutputPort.ObjectProperty = ClockEnableOutputPortOP;
edClockEnableOutputPort.RowSpan = [currRow currRow];
edClockEnableOutputPort.ColSpan = [2 2];
edClockEnableOutputPort.Source = hObjCLI;
edClockEnableOutputPort.Mode = true;
edClockEnableOutputPort.Enabled = enableWidget;

widgets = {lblInputDataType,...
cmbInputDataType,...
lblOutputDataType,...
cmbOutputDataType,...
lblClockEnableOutputPort,...
edClockEnableOutputPort};
    
%--------------------------------------------------------------------------
function [widgets, currRow] = buildAdvancedTab(this, hObjCLI, enableWidget, currRow, tag)
% Widgets on the "Advanced" tab 

VerilogEnabled = strcmpi(hObjCLI.TargetLanguage, 'verilog');
SystemVerilogEnabled = strcmpi(hObjCLI.TargetLanguage, 'systemverilog');
tag = [tag, 'Advanced_'];

chkRepConstantValueOP = 'UseAggregatesForConst';
chkRepConstantValue.Type = 'checkbox';
chkRepConstantValue.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingUseAggregatesForConst');
chkRepConstantValue.Tag = [tag,chkRepConstantValueOP];
chkRepConstantValue.RowSpan = [currRow currRow];
chkRepConstantValue.ColSpan = [1 2];
chkRepConstantValue.Source = this;
chkRepConstantValue.Enabled = ~VerilogEnabled & enableWidget;
chkRepConstantValue.Mode = true;
chkRepConstantValue.ObjectMethod = 'setCheckBox';
chkRepConstantValue.Value        = strcmpi(hObjCLI.(chkRepConstantValueOP), 'on');
chkRepConstantValue.MethodArgs   = {'%value', chkRepConstantValueOP, hObjCLI};
chkRepConstantValue.ArgDataTypes = {'mxArray', 'string', 'mxArray'};

currRow = currRow+1;
chkRisingEdgeOP = 'UseRisingEdge';
chkRisingEdge.Type = 'checkbox';
chkRisingEdge.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingUseRisingEdge');
chkRisingEdge.Tag = [tag,chkRisingEdgeOP];
chkRisingEdge.RowSpan = [currRow currRow];
chkRisingEdge.ColSpan = [1 2];
chkRisingEdge.Source = this;
chkRisingEdge.Enabled = ~VerilogEnabled & enableWidget;
chkRisingEdge.Mode = true;
chkRisingEdge.ObjectMethod = 'setCheckBox';
chkRisingEdge.Value        = strcmpi(hObjCLI.(chkRisingEdgeOP), 'on');
chkRisingEdge.MethodArgs   = {'%value', chkRisingEdgeOP, hObjCLI};
chkRisingEdge.ArgDataTypes = {'mxArray', 'string', 'mxArray'};

currRow = currRow+1;
chkLoopUnrollingOP = 'LoopUnrolling';
chkLoopUnrolling.Type = 'checkbox';
chkLoopUnrolling.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingLoopUnrolling');
chkLoopUnrolling.Tag = [tag,chkLoopUnrollingOP];
chkLoopUnrolling.RowSpan = [currRow currRow];
chkLoopUnrolling.ColSpan = [1 2];
chkLoopUnrolling.Source = this;
if VerilogEnabled == true
    hObjCLI.LoopUnrolling = 'on';
end
chkLoopUnrolling.Enabled = ~VerilogEnabled & enableWidget;

chkLoopUnrolling.Mode = true;
chkLoopUnrolling.ObjectMethod = 'setCheckBox';
chkLoopUnrolling.Value        = strcmpi(hObjCLI.(chkLoopUnrollingOP), 'on');
chkLoopUnrolling.MethodArgs   = {'%value', chkLoopUnrollingOP, hObjCLI};
chkLoopUnrolling.ArgDataTypes = {'mxArray', 'string', 'mxArray'};


currRow = currRow+1;

chkCastBeforeSumOP = 'CastBeforeSum';
chkCastBeforeSum.Type = 'checkbox';
chkCastBeforeSum.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingCastBeforeSum');
chkCastBeforeSum.Tag = [tag,chkCastBeforeSumOP];
chkCastBeforeSum.RowSpan = [currRow currRow];
chkCastBeforeSum.ColSpan = [1 2];
chkCastBeforeSum.Source = this;
chkCastBeforeSum.Mode = true;
chkCastBeforeSum.Enabled = enableWidget;
chkCastBeforeSum.ObjectMethod = 'setCheckBox';
chkCastBeforeSum.Value        = strcmpi(hObjCLI.(chkCastBeforeSumOP), 'on');
chkCastBeforeSum.MethodArgs   = {'%value', chkCastBeforeSumOP, hObjCLI};
chkCastBeforeSum.ArgDataTypes = {'mxArray', 'string', 'mxArray'};


currRow = currRow+1;

chkVerilogTimescaleOP = 'UseVerilogTimescale';
chkVerilogTimescale.Type = 'checkbox';
chkVerilogTimescale.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingUseVerilogTimescale');
chkVerilogTimescale.Tag = [tag,chkVerilogTimescaleOP];
chkVerilogTimescale.RowSpan = [currRow currRow];
chkVerilogTimescale.ColSpan = [1 2];
chkVerilogTimescale.Source = this;
chkVerilogTimescale.Enabled = (VerilogEnabled || SystemVerilogEnabled) & enableWidget;
chkVerilogTimescale.Mode = true;
chkVerilogTimescale.ObjectMethod = 'setCheckBox';
chkVerilogTimescale.Value        = strcmpi(hObjCLI.(chkVerilogTimescaleOP), 'on');
chkVerilogTimescale.MethodArgs   = {'%value', chkVerilogTimescaleOP, hObjCLI};
chkVerilogTimescale.ArgDataTypes = {'mxArray', 'string', 'mxArray'};


currRow = currRow+1;
chkInlineVHDLOP = 'InlineConfigurations';
chkInlineVHDL.Type = 'checkbox';
chkInlineVHDL.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingInlineConfigurations');
chkInlineVHDL.Tag = [tag,chkInlineVHDLOP];
chkInlineVHDL.RowSpan = [currRow currRow];
chkInlineVHDL.ColSpan = [1 2];
chkInlineVHDL.Mode = true;
chkInlineVHDL.Source = this;
chkInlineVHDL.Enabled = ~VerilogEnabled & enableWidget;
chkInlineVHDL.ObjectMethod = 'setCheckBox';
chkInlineVHDL.Value        = strcmpi(hObjCLI.(chkInlineVHDLOP), 'on');
chkInlineVHDL.MethodArgs   = {'%value', chkInlineVHDLOP, hObjCLI};
chkInlineVHDL.ArgDataTypes = {'mxArray', 'string', 'mxArray'};

currRow = currRow+1;
chkConcatenateOP = 'SafeZeroConcat';
chkConcatenate.Type = 'checkbox';
chkConcatenate.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingSafeZeroConcat');
chkConcatenate.Tag = [tag,chkConcatenateOP];
chkConcatenate.RowSpan = [currRow currRow];
chkConcatenate.ColSpan = [1 2];
chkConcatenate.Mode = true;
chkConcatenate.Source = this;
chkConcatenate.Enabled = ~VerilogEnabled & enableWidget;
chkConcatenate.ObjectMethod = 'setCheckBox';
chkConcatenate.Value        = strcmpi(hObjCLI.(chkConcatenateOP), 'on');
chkConcatenate.MethodArgs   = {'%value', chkConcatenateOP, hObjCLI};
chkConcatenate.ArgDataTypes = {'mxArray', 'string', 'mxArray'};

currRow = currRow+1;
DateCommentOP = 'DateComment';
chkDateComment.Name = DAStudio.message('HDLShared:hdldialog:hdlglblsettingDateComment');
chkDateComment.Tag = [tag DateCommentOP];
chkDateComment.Type = 'checkbox';
chkDateComment.RowSpan = [currRow currRow];
chkDateComment.ColSpan = [1 2];
chkDateComment.Mode = true;
chkDateComment.Source = this;
chkDateComment.Enabled = enableWidget;
chkDateComment.ObjectMethod = 'setCheckBox';
chkDateComment.Value        = strcmpi(hObjCLI.(DateCommentOP), 'on');
chkDateComment.MethodArgs   = {'%value', DateCommentOP, hObjCLI};
chkDateComment.ArgDataTypes = {'mxArray', 'string', 'mxArray'};

currRow = currRow+1;
spacer.Type = 'panel';
spacer.RowSpan = [currRow currRow];
spacer.ColSpan = [1 4];

widgets = {...
chkRepConstantValue,...
chkRisingEdge,...
chkLoopUnrolling,...
chkCastBeforeSum,...
chkVerilogTimescale,...
chkInlineVHDL,...
chkConcatenate,...
chkDateComment,...
spacer};

% LocalWords:  fdhdldialog
