mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-02-07 02:15:21 -05:00
changed file:/ to file://
This commit is contained in:
parent
6d569a86f9
commit
0fc8c37f23
@ -90,12 +90,12 @@ void DatabaseTabWidget::newDatabase()
|
|||||||
Database* db = new Database();
|
Database* db = new Database();
|
||||||
db->rootGroup()->setName(tr("Root"));
|
db->rootGroup()->setName(tr("Root"));
|
||||||
dbStruct.dbWidget = new DatabaseWidget(db, this);
|
dbStruct.dbWidget = new DatabaseWidget(db, this);
|
||||||
|
|
||||||
CompositeKey emptyKey;
|
CompositeKey emptyKey;
|
||||||
db->setKey(emptyKey);
|
db->setKey(emptyKey);
|
||||||
|
|
||||||
insertDatabase(db, dbStruct);
|
insertDatabase(db, dbStruct);
|
||||||
|
|
||||||
if (!saveDatabaseAs(db)) {
|
if (!saveDatabaseAs(db)) {
|
||||||
closeDatabase(db);
|
closeDatabase(db);
|
||||||
return;
|
return;
|
||||||
@ -616,19 +616,16 @@ void DatabaseTabWidget::updateTabNameFromDbWidgetSender()
|
|||||||
|
|
||||||
Database* db = dbWidget->database();
|
Database* db = dbWidget->database();
|
||||||
Group *autoload = db->rootGroup()->findChildByName("AutoOpen");
|
Group *autoload = db->rootGroup()->findChildByName("AutoOpen");
|
||||||
if (autoload)
|
if (autoload) {
|
||||||
{
|
|
||||||
const DatabaseManagerStruct& dbStruct = m_dbList.value(db);
|
const DatabaseManagerStruct& dbStruct = m_dbList.value(db);
|
||||||
QFileInfo dbpath(dbStruct.canonicalFilePath);
|
QFileInfo dbpath(dbStruct.canonicalFilePath);
|
||||||
QDir dbFolder(dbpath.canonicalPath());
|
QDir dbFolder(dbpath.canonicalPath());
|
||||||
|
|
||||||
for (auto entry : autoload->entries()) {
|
for (auto entry : autoload->entries()) {
|
||||||
|
if (entry->url().isEmpty() || entry->password().isEmpty()) {
|
||||||
if (entry->url().isEmpty() || entry->password().isEmpty())
|
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
QFileInfo filepath;
|
QFileInfo filepath;
|
||||||
if (entry->url().startsWith("file:/")) {
|
if (entry->url().startsWith("file://")) {
|
||||||
QUrl url(entry->url());
|
QUrl url(entry->url());
|
||||||
filepath.setFile(url.toLocalFile());
|
filepath.setFile(url.toLocalFile());
|
||||||
}
|
}
|
||||||
@ -639,11 +636,11 @@ void DatabaseTabWidget::updateTabNameFromDbWidgetSender()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!filepath.isFile())
|
if (!filepath.isFile()) {
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
openDatabase(filepath.canonicalFilePath(), entry->password(), "");
|
openDatabase(filepath.canonicalFilePath(), entry->password(), "");
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user