[Pkg-owncloud-commits] [owncloud-client] 22/175: ShareDialog: Password ui fixes. #3189

Sandro Knauß hefee-guest at moszumanska.debian.org
Sat Aug 8 10:36:22 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 9507bb4be6b7f0f0774438f1382c7caa46f843df
Author: Christian Kamm <kamm at incasoftware.de>
Date:   Fri May 8 14:53:38 2015 +0200

    ShareDialog: Password ui fixes. #3189
    
    * Change the textedit-empty text to be just "Password"
    * Hide the 'Copy link' button when the share isn't created yet
    * Show the checked and disabled 'Password required' checkbox
      when a password is required.
---
 src/gui/sharedialog.cpp | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/gui/sharedialog.cpp b/src/gui/sharedialog.cpp
index 31c44f6..355f46c 100644
--- a/src/gui/sharedialog.cpp
+++ b/src/gui/sharedialog.cpp
@@ -292,6 +292,7 @@ void ShareDialog::slotSharesFetched(const QVariantMap &reply)
 
         if (data.value("share_type").toInt() == SHARETYPE_PUBLIC) {
             _public_share_id = data.value("id").toULongLong();
+            _ui->pushButton_copy->show();
 
             _ui->widget_shareLink->show();
             _ui->checkBox_shareLink->setChecked(true);
@@ -443,9 +444,10 @@ void ShareDialog::slotCreateShareFetched(const QVariantMap &reply)
     if (code == 403) {
         // there needs to be a password
         _ui->checkBox_password->setChecked(true);
-        _ui->checkBox_password->setVisible(false);
-        _ui->checkBox_password->setText(tr("Public sh&aring requires a password:"));
+        _ui->checkBox_password->setEnabled(false);
+        _ui->checkBox_password->setText(tr("Public sh&aring requires a password"));
         _ui->lineEdit_password->setFocus();
+        _ui->pushButton_copy->hide();
         _ui->widget_shareLink->show();
 
         slotCheckBoxPasswordClicked();
@@ -456,6 +458,7 @@ void ShareDialog::slotCreateShareFetched(const QVariantMap &reply)
     }
 
     _public_share_id = reply.value("ocs").toMap().values("data")[0].toMap().value("id").toULongLong();
+    _ui->pushButton_copy->show();
     getShares();
 }
 
@@ -464,7 +467,7 @@ void ShareDialog::slotCheckBoxPasswordClicked()
     if (_ui->checkBox_password->checkState() == Qt::Checked) {
         _ui->lineEdit_password->show();
         _ui->pushButton_setPassword->show();
-        _ui->lineEdit_password->setPlaceholderText(tr("Choose a password for the public link"));
+        _ui->lineEdit_password->setPlaceholderText(tr("Password"));
         _ui->lineEdit_password->setFocus();
     } else {
         ShareDialog::setPassword(QString());

-- 
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