mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-05-23 08:41:19 -04:00
SSH Agent: Entry context menu control
This commit is contained in:
parent
d41a37c9bc
commit
ef668f552e
10 changed files with 128 additions and 0 deletions
|
@ -299,6 +299,17 @@ QByteArray KeeAgentSettings::toXml() const
|
|||
return ba;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if an entry has KeeAgent settings configured
|
||||
*
|
||||
* @param entry Entry to check the attachment
|
||||
* @return true if XML document exists
|
||||
*/
|
||||
bool KeeAgentSettings::inEntry(const Entry* entry)
|
||||
{
|
||||
return entry->attachments()->hasKey("KeeAgent.settings");
|
||||
}
|
||||
|
||||
/**
|
||||
* Read settings from an entry as an XML attachment.
|
||||
*
|
||||
|
|
|
@ -34,6 +34,7 @@ public:
|
|||
bool fromXml(const QByteArray& ba);
|
||||
QByteArray toXml() const;
|
||||
|
||||
static bool inEntry(const Entry* entry);
|
||||
bool fromEntry(const Entry* entry);
|
||||
void toEntry(Entry* entry) const;
|
||||
bool keyConfigured() const;
|
||||
|
|
|
@ -53,6 +53,8 @@ void SSHAgent::setEnabled(bool enabled)
|
|||
}
|
||||
|
||||
config()->set("SSHAgent", enabled);
|
||||
|
||||
emit enabledChanged(enabled);
|
||||
}
|
||||
|
||||
QString SSHAgent::authSockOverride() const
|
||||
|
|
|
@ -56,6 +56,7 @@ public:
|
|||
|
||||
signals:
|
||||
void error(const QString& message);
|
||||
void enabledChanged(bool enabled);
|
||||
|
||||
public slots:
|
||||
void databaseModeChanged();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue