Don't allow using "-" for unsigned entries in propgrid

The changes of 36f6f8ad49 allowed using
"-" (and also "+") characters even for the unsigned properties, which
hadn't been the case before and doesn't seem desirable, so undo this
part of the changes.

See #1093.
This commit is contained in:
Vadim Zeitlin 2019-01-07 04:29:45 +01:00
parent cfe4a10995
commit 9ab3acee18

View File

@ -162,8 +162,7 @@ wxNumericPropertyValidator::
{
long style = GetStyle();
// always allow plus and minus signs
wxString allowedChars("+-");
wxString allowedChars;
switch ( base )
{
@ -185,7 +184,11 @@ wxNumericPropertyValidator::
style |= wxFILTER_DIGITS;
}
if ( numericType == Float )
if ( numericType == Signed )
{
allowedChars += wxS("-+");
}
else if ( numericType == Float )
{
allowedChars += wxS("eE");