allow any filetype to be opened as a database

This commit is contained in:
Franklin Strube 2012-06-05 13:41:21 -04:00 committed by Florian Geyer
parent 8e8efc67e6
commit 21302782e1

View File

@ -82,8 +82,9 @@ void DatabaseTabWidget::newDatabase()
void DatabaseTabWidget::openDatabase() void DatabaseTabWidget::openDatabase()
{ {
QString filter = QString("%1 (*.kdbx);;%2 (*)").arg(tr("KeePass 2 Database"), tr("All files"));
QString fileName = fileDialog()->getOpenFileName(m_window, tr("Open database"), QString(), QString fileName = fileDialog()->getOpenFileName(m_window, tr("Open database"), QString(),
tr("KeePass 2 Database").append(" (*.kdbx)")); filter);
if (!fileName.isEmpty()) { if (!fileName.isEmpty()) {
openDatabase(fileName); openDatabase(fileName);
} }