Make sure copy actions are disabled when database is locked.

Closes #189
This commit is contained in:
Florian Geyer 2014-05-03 08:28:56 +02:00
parent e263c475c9
commit b718e9d8f2

View File

@ -313,6 +313,11 @@ void MainWindow::setMenuActionState(DatabaseWidget::Mode mode)
Q_FOREACH (QAction* action, m_ui->menuGroups->actions()) { Q_FOREACH (QAction* action, m_ui->menuGroups->actions()) {
action->setEnabled(false); action->setEnabled(false);
} }
m_ui->actionEntryCopyTitle->setEnabled(false);
m_ui->actionEntryCopyUsername->setEnabled(false);
m_ui->actionEntryCopyPassword->setEnabled(false);
m_ui->actionEntryCopyURL->setEnabled(false);
m_ui->actionEntryCopyNotes->setEnabled(false);
m_ui->menuEntryCopyAttribute->setEnabled(false); m_ui->menuEntryCopyAttribute->setEnabled(false);
m_ui->actionSearch->setEnabled(false); m_ui->actionSearch->setEnabled(false);
@ -335,6 +340,11 @@ void MainWindow::setMenuActionState(DatabaseWidget::Mode mode)
Q_FOREACH (QAction* action, m_ui->menuGroups->actions()) { Q_FOREACH (QAction* action, m_ui->menuGroups->actions()) {
action->setEnabled(false); action->setEnabled(false);
} }
m_ui->actionEntryCopyTitle->setEnabled(false);
m_ui->actionEntryCopyUsername->setEnabled(false);
m_ui->actionEntryCopyPassword->setEnabled(false);
m_ui->actionEntryCopyURL->setEnabled(false);
m_ui->actionEntryCopyNotes->setEnabled(false);
m_ui->menuEntryCopyAttribute->setEnabled(false); m_ui->menuEntryCopyAttribute->setEnabled(false);
m_ui->actionSearch->setEnabled(false); m_ui->actionSearch->setEnabled(false);