Skip to content
Snippets Groups Projects
Commit 46bfc6cb authored by Ming Rui Zhang's avatar Ming Rui Zhang Committed by Andreas Traczyk
Browse files

settingswidget: hide unnecessary ui components for account manager

Change-Id: Ib1bf1331cb717c07a15dea5d3aa812d4e8af2c6d
parent 405158c3
No related branches found
No related tags found
No related merge requests found
...@@ -440,6 +440,11 @@ void SettingsWidget::updateAccountInfoDisplayed() ...@@ -440,6 +440,11 @@ void SettingsWidget::updateAccountInfoDisplayed()
auto& accInfo = LRCInstance::getCurrentAccountInfo(); auto& accInfo = LRCInstance::getCurrentAccountInfo();
auto accConfig = LRCInstance::accountModel().getAccountConfig(LRCInstance::getCurrAccId()); auto accConfig = LRCInstance::accountModel().getAccountConfig(LRCInstance::getCurrAccId());
bool showLocalAccountConfig = accConfig.managerUri.empty();
ui->passwdPushButton->setVisible(showLocalAccountConfig);
ui->btnExportAccount->setVisible(showLocalAccountConfig);
ui->linkDevPushButton->setVisible(showLocalAccountConfig);
ui->usernameSIP->setText(QString::fromStdString(accConfig.username)); ui->usernameSIP->setText(QString::fromStdString(accConfig.username));
ui->hostnameSIP->setText(QString::fromStdString(accConfig.hostname)); ui->hostnameSIP->setText(QString::fromStdString(accConfig.hostname));
ui->passSIPlineEdit->setText(QString::fromStdString(accConfig.password)); ui->passSIPlineEdit->setText(QString::fromStdString(accConfig.password));
...@@ -766,7 +771,9 @@ void SettingsWidget::updateAndShowDevicesSlot() ...@@ -766,7 +771,9 @@ void SettingsWidget::updateAndShowDevicesSlot()
{ {
ui->settingsListWidget->clear(); ui->settingsListWidget->clear();
if (LRCInstance::getCurrAccConfig().managerUri.empty()) {
ui->linkDevPushButton->show(); ui->linkDevPushButton->show();
}
auto deviceList = LRCInstance::getCurrentAccountInfo().deviceModel->getAllDevices(); auto deviceList = LRCInstance::getCurrentAccountInfo().deviceModel->getAllDevices();
......
...@@ -376,7 +376,7 @@ ...@@ -376,7 +376,7 @@
</size> </size>
</property> </property>
<property name="currentIndex"> <property name="currentIndex">
<number>3</number> <number>1</number>
</property> </property>
<widget class="QWidget" name="generalSettings"> <widget class="QWidget" name="generalSettings">
<property name="sizePolicy"> <property name="sizePolicy">
...@@ -1416,7 +1416,7 @@ ...@@ -1416,7 +1416,7 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>705</width> <width>749</width>
<height>1387</height> <height>1387</height>
</rect> </rect>
</property> </property>
...@@ -1913,7 +1913,7 @@ ...@@ -1913,7 +1913,7 @@
</layout> </layout>
</item> </item>
<item> <item>
<spacer name="verticalSpacer_30"> <spacer name="verticalSpacerBetweenlblRegisteredNameAndChangePassButton">
<property name="orientation"> <property name="orientation">
<enum>Qt::Vertical</enum> <enum>Qt::Vertical</enum>
</property> </property>
...@@ -1975,7 +1975,7 @@ ...@@ -1975,7 +1975,7 @@
<property name="sizeHint" stdset="0"> <property name="sizeHint" stdset="0">
<size> <size>
<width>40</width> <width>40</width>
<height>20</height> <height>0</height>
</size> </size>
</property> </property>
</spacer> </spacer>
...@@ -2016,7 +2016,7 @@ ...@@ -2016,7 +2016,7 @@
<property name="sizeHint" stdset="0"> <property name="sizeHint" stdset="0">
<size> <size>
<width>40</width> <width>40</width>
<height>20</height> <height>0</height>
</size> </size>
</property> </property>
</spacer> </spacer>
...@@ -2085,7 +2085,7 @@ ...@@ -2085,7 +2085,7 @@
</spacer> </spacer>
</item> </item>
<item> <item>
<layout class="QVBoxLayout" name="verticalLayout_18"> <layout class="QVBoxLayout" name="linkedDeviceVerticalLayout">
<property name="topMargin"> <property name="topMargin">
<number>0</number> <number>0</number>
</property> </property>
...@@ -4255,12 +4255,6 @@ ...@@ -4255,12 +4255,6 @@
<header>iconbutton.h</header> <header>iconbutton.h</header>
<container>1</container> <container>1</container>
</customwidget> </customwidget>
<customwidget>
<class>PhotoboothWidget</class>
<extends>QWidget</extends>
<header>photoboothwidget.h</header>
<container>1</container>
</customwidget>
<customwidget> <customwidget>
<class>LevelMeter</class> <class>LevelMeter</class>
<extends>QWidget</extends> <extends>QWidget</extends>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment