mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-10-01 01:26:01 -04:00
Merge pull request #422 from weslly/feature/osx-proxy-icon
Add proxy icon to title bar in OSX
This commit is contained in:
commit
99036ec151
@ -552,6 +552,16 @@ bool DatabaseTabWidget::isModified(int index)
|
||||
return indexDatabaseManagerStruct(index).modified;
|
||||
}
|
||||
|
||||
QString DatabaseTabWidget::databasePath(int index)
|
||||
{
|
||||
if (index == -1) {
|
||||
index = currentIndex();
|
||||
}
|
||||
|
||||
return indexDatabaseManagerStruct(index).filePath;
|
||||
}
|
||||
|
||||
|
||||
void DatabaseTabWidget::updateTabName(Database* db)
|
||||
{
|
||||
int index = databaseIndex(db);
|
||||
|
@ -81,6 +81,7 @@ public slots:
|
||||
bool isModified(int index = -1);
|
||||
void performGlobalAutoType();
|
||||
void lockDatabases();
|
||||
QString databasePath(int index = -1);
|
||||
|
||||
signals:
|
||||
void tabNameChanged();
|
||||
|
@ -530,6 +530,12 @@ void MainWindow::updateWindowTitle()
|
||||
windowTitle = QString("%1 - %2").arg(customWindowTitlePart, BaseWindowTitle);
|
||||
}
|
||||
|
||||
if (customWindowTitlePart.isEmpty() || stackedWidgetIndex == 1) {
|
||||
setWindowFilePath("");
|
||||
} else {
|
||||
setWindowFilePath(m_ui->tabWidget->databasePath(tabWidgetIndex));
|
||||
}
|
||||
|
||||
setWindowModified(m_ui->tabWidget->isModified(tabWidgetIndex));
|
||||
|
||||
setWindowTitle(windowTitle);
|
||||
|
Loading…
Reference in New Issue
Block a user