/// <summary> /// 删除类 /// </summary> public void deleteClass() { List <FCGridRow> selectedRows = m_tvCollection.SelectedRows; int selectedRowsSize = selectedRows.Count; if (selectedRowsSize > 0) { if (m_collectionName == "TabPages") { FCTabControl tabControl = m_target as FCTabControl; FCTabPage tabPage = selectedRows[0].Tag as FCTabPage; m_xml.removeControl(tabPage); m_tvCollection.removeRow(selectedRows[0]); m_tvCollection.update(); tabControl.update(); } else if (m_collectionName == "Columns") { FCGrid grid = m_target as FCGrid; FCGridColumn column = selectedRows[0].Tag as FCGridColumn; grid.removeColumn(column); m_xml.m_controls.Remove(column); m_xml.Nodes[column].ParentNode.RemoveChild(m_xml.Nodes[column]); m_xml.Nodes.Remove(column); m_tvCollection.removeRow(selectedRows[0]); m_tvCollection.update(); grid.update(); } Native.invalidate(); m_designerDiv.saveUndo(); } }