[Pkg-owncloud-commits] [owncloud-client] 131/218: UI: Allow folder expanding from button click #3585

Sandro Knauß hefee-guest at moszumanska.debian.org
Sat Oct 17 14:30:57 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 15e4d9e317071d39ad74140f43bc85ee645cdef1
Author: Markus Goetz <markus at woboq.com>
Date:   Tue Sep 15 21:07:04 2015 -0400

    UI: Allow folder expanding from button click #3585
---
 src/gui/accountsettings.cpp | 7 +++++++
 src/gui/accountsettings.h   | 1 +
 2 files changed, 8 insertions(+)

diff --git a/src/gui/accountsettings.cpp b/src/gui/accountsettings.cpp
index 6bc0d73..a951b62 100644
--- a/src/gui/accountsettings.cpp
+++ b/src/gui/accountsettings.cpp
@@ -128,6 +128,11 @@ AccountSettings::AccountSettings(AccountState *accountState, QWidget *parent) :
         ui->_folderList, SLOT(expand(const QModelIndex &)));
 }
 
+void AccountSettings::doExpand()
+{
+    ui->_folderList->expandToDepth(1);
+}
+
 void AccountSettings::slotCustomContextMenuRequested(const QPoint &pos)
 {
     QTreeView *tv = ui->_folderList;
@@ -148,6 +153,8 @@ void AccountSettings::slotCustomContextMenuRequested(const QPoint &pos)
     menu->setAttribute(Qt::WA_DeleteOnClose);
     connect(menu->addAction(tr("Open folder")), SIGNAL(triggered(bool)),
             this, SLOT(slotOpenCurrentFolder()));
+    connect(menu->addAction(tr("Choose What to Sync")), SIGNAL(triggered(bool)),
+            this, SLOT(doExpand()));
     connect(menu->addAction(folderPaused ? tr("Resume sync") : tr("Pause sync")), SIGNAL(triggered(bool)),
             this, SLOT(slotEnableCurrentFolder()));
     connect(menu->addAction(tr("Remove sync")), SIGNAL(triggered(bool)),
diff --git a/src/gui/accountsettings.h b/src/gui/accountsettings.h
index c20c464..b63a75a 100644
--- a/src/gui/accountsettings.h
+++ b/src/gui/accountsettings.h
@@ -80,6 +80,7 @@ protected slots:
     void slotDeleteAccount();
     void refreshSelectiveSyncStatus();
     void slotCustomContextMenuRequested(const QPoint&);
+    void doExpand();
 
 private:
     void showConnectionLabel(const QString& message,

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