BUG: fix for 6462, delete key should delete the current char
This commit is contained in:
parent
2f20b9d33b
commit
b3b4350879
|
@ -170,14 +170,21 @@ bool cmCursesStringWidget::HandleInput(int& key, cmCursesMainForm* fm,
|
||||||
{
|
{
|
||||||
form_driver(form, REQ_END_FIELD);
|
form_driver(form, REQ_END_FIELD);
|
||||||
}
|
}
|
||||||
else if ( key == ctrl('d') || key == 127 ||
|
else if ( key == 127 ||
|
||||||
key == KEY_BACKSPACE || key == KEY_DC )
|
key == KEY_BACKSPACE )
|
||||||
{
|
{
|
||||||
if ( form->curcol > 0 )
|
if ( form->curcol > 0 )
|
||||||
{
|
{
|
||||||
form_driver(form, REQ_DEL_PREV);
|
form_driver(form, REQ_DEL_PREV);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if ( key == ctrl('d') ||key == KEY_DC )
|
||||||
|
{
|
||||||
|
if ( form->curcol > 0 )
|
||||||
|
{
|
||||||
|
form_driver(form, REQ_DEL_CHAR);
|
||||||
|
}
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this->OnType(key, fm, w);
|
this->OnType(key, fm, w);
|
||||||
|
|
Loading…
Reference in New Issue