[Pkg-owncloud-commits] [owncloud-client] 36/159: HttpCreds: Fill pw dialog with previous password. #2848 #2879
Sandro Knauß
hefee-guest at moszumanska.debian.org
Fri May 1 13:05:19 UTC 2015
This is an automated email from the git hooks/post-receive script.
hefee-guest pushed a commit to branch master
in repository owncloud-client.
commit 3cef771868ee94d3b0f5b0575d1c3c4d3b32d394
Author: Christian Kamm <kamm at incasoftware.de>
Date: Wed Mar 25 13:27:40 2015 +0100
HttpCreds: Fill pw dialog with previous password. #2848 #2879
---
src/libsync/creds/httpcredentials.cpp | 5 ++++-
src/libsync/creds/httpcredentials.h | 1 +
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/libsync/creds/httpcredentials.cpp b/src/libsync/creds/httpcredentials.cpp
index 92ef227..2d5569d 100644
--- a/src/libsync/creds/httpcredentials.cpp
+++ b/src/libsync/creds/httpcredentials.cpp
@@ -313,6 +313,9 @@ void HttpCredentials::slotReadJobDone(QKeychain::Job *job)
void HttpCredentials::invalidateToken()
{
+ if (! _password.isEmpty()) {
+ _previousPassword = _password;
+ }
_password = QString();
_ready = false;
@@ -387,7 +390,7 @@ QString HttpCredentialsGui::queryPassword(bool *ok)
QString str = QInputDialog::getText(0, tr("Enter Password"),
tr("Please enter %1 password for user '%2':")
.arg(Theme::instance()->appNameGUI(), _user),
- QLineEdit::Password, QString(), ok);
+ QLineEdit::Password, _previousPassword, ok);
return str;
} else {
return QString();
diff --git a/src/libsync/creds/httpcredentials.h b/src/libsync/creds/httpcredentials.h
index 9f60f3b..f0fb4b4 100644
--- a/src/libsync/creds/httpcredentials.h
+++ b/src/libsync/creds/httpcredentials.h
@@ -64,6 +64,7 @@ private Q_SLOTS:
protected:
QString _user;
QString _password;
+ QString _previousPassword;
private:
QString _certificatePath;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud-client.git
More information about the Pkg-owncloud-commits
mailing list