Eeschema: fix broken sheet name edit control validator.
This commit is contained in:
parent
4fb643df93
commit
71b3ab432c
|
@ -46,10 +46,17 @@ SCH_FIELD_VALIDATOR::SCH_FIELD_VALIDATOR( bool aIsLibEditor, int aFieldId, wxSt
|
||||||
wxString excludes( wxT( "\r\n\t" ) );
|
wxString excludes( wxT( "\r\n\t" ) );
|
||||||
|
|
||||||
// The reference and sheet name fields cannot contain spaces.
|
// The reference and sheet name fields cannot contain spaces.
|
||||||
if( aFieldId == REFERENCE_FIELD || m_fieldId == SHEETNAME_V )
|
if( aFieldId == REFERENCE_FIELD )
|
||||||
{
|
{
|
||||||
excludes += wxT( " " );
|
excludes += wxT( " " );
|
||||||
}
|
}
|
||||||
|
else if( m_fieldId == SHEETNAME_V )
|
||||||
|
{
|
||||||
|
// Does it make sense to exclude the colon and back slash characters? The forward slash
|
||||||
|
// makes sense because it is used as the separator when generating human readable sheet
|
||||||
|
// paths.
|
||||||
|
excludes += wxT( ":/\\" );
|
||||||
|
}
|
||||||
else if( aFieldId == VALUE_FIELD && m_isLibEditor )
|
else if( aFieldId == VALUE_FIELD && m_isLibEditor )
|
||||||
{
|
{
|
||||||
excludes += wxT( " :/\\" );
|
excludes += wxT( " :/\\" );
|
||||||
|
|
Loading…
Reference in New Issue