예제 #1
0
 /// ------------------------------------------------------------------------------------
 /// <summary>
 /// Handles the CellValueChanged event of the gridProperties control.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="T:System.Windows.Forms.DataGridViewCellEventArgs"/> instance containing the event data.</param>
 /// ------------------------------------------------------------------------------------
 void gridProperties_CellValueChanged(object sender, DataGridViewCellEventArgs e)
 {
     if (e.ColumnIndex == 0 && e.RowIndex >= 0)
     {
         DataGridViewCellCollection cells = gridProperties.Rows[e.RowIndex].Cells;
         FDOClassProperty           prop  = cells[2].Value as FDOClassProperty;
         prop.Displayed = (bool)cells[0].Value;
     }
 }
예제 #2
0
 /// ------------------------------------------------------------------------------------
 /// <summary>
 /// Handles the CellFormatting event of the gridProperties control.
 /// </summary>
 /// ------------------------------------------------------------------------------------
 private void gridProperties_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
 {
     if (e.ColumnIndex == 1 && e.RowIndex >= 0 && !m_showCmObjProps)
     {
         DataGridViewCellCollection cells = gridProperties.Rows[e.RowIndex].Cells;
         FDOClassProperty           prop  = cells[2].Value as FDOClassProperty;
         if (FDOClassList.IsCmObjectProperty(prop.Name))
         {
             e.CellStyle.ForeColor = SystemColors.GrayText;
         }
     }
 }