|
|
@@ -21,6 +21,7 @@
|
|
|
#include "generalsettings.h"
|
|
|
#include "networksettings.h"
|
|
|
#include "accountsettings.h"
|
|
|
+#include "accountstate.h"
|
|
|
#include "creds/abstractcredentials.h"
|
|
|
#include "configfile.h"
|
|
|
#include "progressdispatcher.h"
|
|
|
@@ -121,6 +122,7 @@ SettingsDialogMac::SettingsDialogMac(ownCloudGui *gui, QWidget *parent)
|
|
|
|
|
|
ConfigFile cfg;
|
|
|
cfg.restoreGeometry(this);
|
|
|
+ _activitySettings->setNotificationRefreshInterval(cfg.notificationRefreshInterval());
|
|
|
}
|
|
|
|
|
|
void SettingsDialogMac::closeEvent(QCloseEvent *event)
|
|
|
@@ -160,6 +162,9 @@ void SettingsDialogMac::accountAdded(AccountState *s)
|
|
|
connect(s->account().data(), &Account::accountChangedAvatar, this, &SettingsDialogMac::slotAccountAvatarChanged);
|
|
|
connect(s->account().data(), &Account::accountChangedDisplayName, this, &SettingsDialogMac::slotAccountDisplayNameChanged);
|
|
|
|
|
|
+ // Refresh immediatly when getting online
|
|
|
+ connect(s, &AccountState::isConnectedChanged, this, &SettingsDialogMac::slotRefreshActivityAccountStateSender);
|
|
|
+
|
|
|
slotRefreshActivity(s);
|
|
|
}
|
|
|
|
|
|
@@ -175,6 +180,11 @@ void SettingsDialogMac::accountRemoved(AccountState *s)
|
|
|
_activitySettings->slotRemoveAccount(s);
|
|
|
}
|
|
|
|
|
|
+void SettingsDialogMac::slotRefreshActivityAccountStateSender()
|
|
|
+{
|
|
|
+ slotRefreshActivity(qobject_cast<AccountState*>(sender()));
|
|
|
+}
|
|
|
+
|
|
|
void SettingsDialogMac::slotRefreshActivity(AccountState *accountState)
|
|
|
{
|
|
|
if (accountState) {
|