sim - Don't allow user to delete the type-in measure entry
This commit is contained in:
parent
1170fb2e18
commit
9006f38e70
|
@ -366,7 +366,9 @@ void MEASUREMENTS_GRID_TRICKS::showPopupMenu( wxMenu& menu, wxGridEvent& aEvent
|
||||||
if( m_menuCol == COL_MEASUREMENT_VALUE )
|
if( m_menuCol == COL_MEASUREMENT_VALUE )
|
||||||
menu.Append( MYID_FORMAT_VALUE, _( "Format Value..." ) );
|
menu.Append( MYID_FORMAT_VALUE, _( "Format Value..." ) );
|
||||||
|
|
||||||
|
if( m_menuRow < ( m_grid->GetNumberRows() - 1 ) )
|
||||||
menu.Append( MYID_DELETE_MEASUREMENT, _( "Delete Measurement" ) );
|
menu.Append( MYID_DELETE_MEASUREMENT, _( "Delete Measurement" ) );
|
||||||
|
|
||||||
menu.AppendSeparator();
|
menu.AppendSeparator();
|
||||||
|
|
||||||
GRID_TRICKS::showPopupMenu( menu, aEvent );
|
GRID_TRICKS::showPopupMenu( menu, aEvent );
|
||||||
|
@ -1211,10 +1213,13 @@ void SIM_PLOT_FRAME::SetMeasureFormat( int aRow, const SPICE_VALUE_FORMAT& aForm
|
||||||
|
|
||||||
|
|
||||||
void SIM_PLOT_FRAME::DeleteMeasurement( int aRow )
|
void SIM_PLOT_FRAME::DeleteMeasurement( int aRow )
|
||||||
|
{
|
||||||
|
if( aRow < ( m_measurementsGrid->GetNumberRows() - 1 ) )
|
||||||
{
|
{
|
||||||
m_measurementsGrid->DeleteRows( aRow, 1 );
|
m_measurementsGrid->DeleteRows( aRow, 1 );
|
||||||
m_workbookModified = true;
|
m_workbookModified = true;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void SIM_PLOT_FRAME::onMeasurementsGridCellChanged( wxGridEvent& aEvent )
|
void SIM_PLOT_FRAME::onMeasurementsGridCellChanged( wxGridEvent& aEvent )
|
||||||
|
|
Loading…
Reference in New Issue