|
|
@@ -113,12 +113,6 @@ Qt::ItemFlags FolderStatusModel::flags(const QModelIndex &index) const
|
|
|
ret = Qt::ItemNeverHasChildren;
|
|
|
if (!_accountState->isConnected()) {
|
|
|
return ret;
|
|
|
- } else if (_folders.count() == 1) {
|
|
|
- auto remotePath = _folders.at(0)._folder->remotePath();
|
|
|
- // special case when syncing the entire owncloud: disable the add folder button (#3438)
|
|
|
- if (remotePath.isEmpty() || remotePath == QLatin1String("/")) {
|
|
|
- return ret;
|
|
|
- }
|
|
|
}
|
|
|
return Qt::ItemIsEnabled | ret;
|
|
|
}
|
|
|
@@ -148,15 +142,6 @@ QVariant FolderStatusModel::data(const QModelIndex &index, int role) const
|
|
|
if (!_accountState->isConnected()) {
|
|
|
return tr("You need to be connected to add a folder");
|
|
|
}
|
|
|
- if (_folders.count() == 1) {
|
|
|
- auto remotePath = _folders.at(0)._folder->remotePath();
|
|
|
- if (remotePath.isEmpty() || remotePath == QLatin1String("/")) {
|
|
|
- // Syncing the entire owncloud: disable the add folder button (#3438)
|
|
|
- return tr("Adding folder is disabled because you are already syncing all your files. "
|
|
|
- "If you want to sync multiple folders, please remove the currently "
|
|
|
- "configured root folder.");
|
|
|
- }
|
|
|
- }
|
|
|
return tr("Click this button to add a folder to synchronize.");
|
|
|
}
|
|
|
return QVariant();
|