mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-26 06:55:59 +03:00
Move sharesChanged signal emission to handlePlaceholderLinkShare rather than repeating each time this method is called
Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
parent
f05e44a24a
commit
2e69a9c59a
1 changed files with 2 additions and 4 deletions
|
@ -345,6 +345,8 @@ void ShareModel::handlePlaceholderLinkShare()
|
|||
} else if (!linkSharePresent && !placeholderLinkSharePresent && publicLinkSharesEnabled()) {
|
||||
slotAddShare(_placeholderLinkShare);
|
||||
}
|
||||
|
||||
Q_EMIT sharesChanged();
|
||||
}
|
||||
|
||||
void ShareModel::slotPropfindReceived(const QVariantMap &result)
|
||||
|
@ -402,7 +404,6 @@ void ShareModel::slotSharesFetched(const QList<SharePtr> &shares)
|
|||
}
|
||||
|
||||
handlePlaceholderLinkShare();
|
||||
Q_EMIT sharesChanged();
|
||||
}
|
||||
|
||||
void ShareModel::setupInternalLinkShare()
|
||||
|
@ -479,7 +480,6 @@ void ShareModel::slotAddShare(const SharePtr &share)
|
|||
}
|
||||
|
||||
handlePlaceholderLinkShare();
|
||||
Q_EMIT sharesChanged();
|
||||
}
|
||||
|
||||
void ShareModel::slotRemoveShareWithId(const QString &shareId)
|
||||
|
@ -506,8 +506,6 @@ void ShareModel::slotRemoveShareWithId(const QString &shareId)
|
|||
endRemoveRows();
|
||||
|
||||
handlePlaceholderLinkShare();
|
||||
|
||||
Q_EMIT sharesChanged();
|
||||
}
|
||||
|
||||
void ShareModel::slotServerError(const int code, const QString &message)
|
||||
|
|
Loading…
Reference in a new issue