From adbce87ccd8e595b51dadf102eb2fe631fbcc2b2 Mon Sep 17 00:00:00 2001 From: Florian Geyer Date: Sun, 27 May 2012 17:06:04 +0200 Subject: [PATCH] Improve update of enabled state of group actions. --- src/gui/DatabaseWidget.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/gui/DatabaseWidget.cpp b/src/gui/DatabaseWidget.cpp index daa37460c..6e4c0686c 100644 --- a/src/gui/DatabaseWidget.cpp +++ b/src/gui/DatabaseWidget.cpp @@ -601,10 +601,9 @@ void DatabaseWidget::clearLastGroup(Group* group) void DatabaseWidget::updateGroupActions(Group* group) { - bool inSearch = m_lastGroup; - m_actionGroupNew->setEnabled(group && !inSearch); - m_actionGroupEdit->setEnabled(group && !inSearch); - m_actionGroupDelete->setEnabled(group && !inSearch && canDeleteCurrentGoup()); + m_actionGroupNew->setEnabled(group); + m_actionGroupEdit->setEnabled(group); + m_actionGroupDelete->setEnabled(group && canDeleteCurrentGoup()); } void DatabaseWidget::updateEntryActions()