Просмотр исходного кода

ccmake: Allow DEL key in first column

Change test if DEL key is allowed from 'curcol > 0' to 'curcol >= 0', as
deleting forward is reasonable in the first column (and probably
expected by users to work).

Support for DEL was first added in commit b3b43508 (BUG: fix for 6462,
delete key should delete the current char, 2008-08-19).  The commit
appears to have copied the original logic from the backspace code so the
old 'curcol > 0' logic was accidental rather than intentional.
Matthew Woehlke 13 лет назад
Родитель
Сommit
d424de48dc
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      Source/CursesDialog/cmCursesStringWidget.cxx

+ 1 - 1
Source/CursesDialog/cmCursesStringWidget.cxx

@@ -175,7 +175,7 @@ bool cmCursesStringWidget::HandleInput(int& key, cmCursesMainForm* fm,
       }
     else if ( key == ctrl('d') ||key == KEY_DC )
       {
-      if ( form->curcol > 0 )
+      if ( form->curcol >= 0 )
         {
         form_driver(form, REQ_DEL_CHAR);
         }