// 复选框选项改变事件 private void CheckBox_CheckedChanged(object sender, EventArgs e) { CheckBox checkBox = (CheckBox)sender; bool bl = checkBox.Checked; CheckState checkState = checkBox.CheckState; if (全选反选_check.Equals(checkBox)) { if (checkBox.Capture) { checkBox.ThreeState = false; ControlsUtils.SetControlsChecked(结果选项容器.Controls, bl); } } else if (生成get_set_check.Equals(checkBox)) { isGetAndSet = bl; get_set规则_check.Enabled = bl; 生成get_set_red.Enabled = bl; 只生成get_rad.Enabled = bl; 只生成set_rad.Enabled = bl; get_set对中_red.Enabled = bl; 先get后set_red.Enabled = bl; 先set后get_red.Enabled = bl; 生成get_set注释_check.Enabled = bl && 生成注释_check.Checked; } else if (生成构造函数_check.Equals(checkBox)) { isConstructor = bl; 构造器生成注释_check.Enabled = bl && 生成注释_check.Checked; } else if (生成注释_check.Equals(checkBox)) { isComment = bl; 生成字段注释_check.Enabled = bl; 生成get_set注释_check.Enabled = bl && 生成get_set_check.Checked; 构造器生成注释_check.Enabled = bl && 生成构造函数_check.Checked; } else if (生成深拷贝方法_check.Equals(checkBox)) { isDeepClone = bl; } else if (生成ToString_check.Equals(checkBox)) { isToString = bl; } else if (生成字段注释_check.Equals(checkBox)) { isFieldComment = bl; } else if (生成get_set注释_check.Equals(checkBox)) { isGetSetComment = bl; } else if (构造器生成注释_check.Equals(checkBox)) { isConstrComment = bl; } else if (生成序列化_check.Equals(checkBox)) { isSerialization = bl; } else if (get_set规则_check.Equals(checkBox)) { checkBox.Checked = true; } if (!全选反选_check.Equals(checkBox) && !全选反选_check.Capture) { isSelectAllChecked(); } }