mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-11-21 07:20:28 -05:00
Add more comprehensive messages when adding custom icons
* Error messages now display for 15 seconds and are closable * Add button is always enabled
This commit is contained in:
parent
b07d4efe5f
commit
2e292699b7
3 changed files with 63 additions and 24 deletions
|
|
@ -125,8 +125,14 @@ void EditWidget::enableApplyButton(bool enabled)
|
|||
|
||||
void EditWidget::showMessage(const QString& text, MessageWidget::MessageType type)
|
||||
{
|
||||
m_ui->messageWidget->setCloseButtonVisible(false);
|
||||
m_ui->messageWidget->showMessage(text, type, 2000);
|
||||
// Show error messages for a longer time to make sure the user can read them
|
||||
if (type == MessageWidget::Error) {
|
||||
m_ui->messageWidget->setCloseButtonVisible(true);
|
||||
m_ui->messageWidget->showMessage(text, type, 15000);
|
||||
} else {
|
||||
m_ui->messageWidget->setCloseButtonVisible(false);
|
||||
m_ui->messageWidget->showMessage(text, type, 2000);
|
||||
}
|
||||
}
|
||||
|
||||
void EditWidget::hideMessage()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue