MAINT-8289 FIXED Deleting inventory directory while keeping [Delete] key pressed

master
maxim_productengine 2018-02-14 17:55:37 +02:00
parent 52eb540cca
commit 5ab314bb95
1 changed files with 2 additions and 2 deletions

View File

@ -1630,12 +1630,12 @@ BOOL LLLineEditor::handleUnicodeCharHere(llwchar uni_char)
BOOL LLLineEditor::canDoDelete() const
{
return ( !mReadOnly && mText.length() > 0 && (!mPassDelete || (hasSelection() || (getCursor() < mText.length()))) );
return ( !mReadOnly && (!mPassDelete || (hasSelection() || (getCursor() < mText.length()))) );
}
void LLLineEditor::doDelete()
{
if (canDoDelete())
if (canDoDelete() && mText.length() > 0)
{
// Prepare for possible rollback
LLLineEditorRollback rollback( this );