mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-26 23:28:14 +03:00
SettingsDialog: show "Account" for the tab name for branded client
https://github.com/owncloud/enterprise/issues/863
This commit is contained in:
parent
e7e918dafe
commit
bb6a50be02
2 changed files with 9 additions and 4 deletions
|
@ -190,10 +190,15 @@ void SettingsDialog::showActivityPage()
|
|||
void SettingsDialog::accountAdded(AccountState *s)
|
||||
{
|
||||
auto height = _toolBar->sizeHint().height();
|
||||
|
||||
bool brandingSingleAccount = !Theme::instance()->multiAccount();
|
||||
|
||||
auto accountAction = createColorAwareAction(QLatin1String(":/client/resources/account.png"),
|
||||
s->account()->displayName());
|
||||
accountAction->setToolTip(s->account()->displayName());
|
||||
accountAction->setIconText(s->shortDisplayNameForSettings(height * buttonSizeRatio));
|
||||
brandingSingleAccount ? tr("Account") : s->account()->displayName());
|
||||
if (!brandingSingleAccount) {
|
||||
accountAction->setToolTip(s->account()->displayName());
|
||||
accountAction->setIconText(s->shortDisplayNameForSettings(height * buttonSizeRatio));
|
||||
}
|
||||
_toolBar->insertAction(_toolBar->actions().at(0), accountAction);
|
||||
auto accountSettings = new AccountSettings(s, this);
|
||||
_ui->stack->insertWidget(0 , accountSettings);
|
||||
|
|
|
@ -117,7 +117,7 @@ void SettingsDialogMac::accountAdded(AccountState *s)
|
|||
QIcon accountIcon = MacStandardIcon::icon(MacStandardIcon::UserAccounts);
|
||||
auto accountSettings = new AccountSettings(s, this);
|
||||
|
||||
QString displayName = s->shortDisplayNameForSettings();
|
||||
QString displayName = Theme::instance()->multiAccount() ? s->shortDisplayNameForSettings() : tr("Account");
|
||||
|
||||
insertPreferencesPanel(0, accountIcon, displayName, accountSettings);
|
||||
|
||||
|
|
Loading…
Reference in a new issue