Add configuration option to disable magic

This commit is contained in:
Michael Zanetti 2021-12-15 12:53:50 +01:00
parent d18b5eaa43
commit a8abdff274
3 changed files with 4 additions and 2 deletions

View File

@ -10,6 +10,7 @@ ConfigurationBase {
showCommunityLinks: true
magicEnabled: true
networkSettingsEnabled: true
apiSettingsEnabled: true
mqttSettingsEnabled: true

View File

@ -9,7 +9,8 @@ Item {
property bool showCommunityLinks: false
// Enable/disable entries in the system settings
// Enable/disable certain features
property bool magicEnabled: false
property bool networkSettingsEnabled: false
property bool apiSettingsEnabled: false
property bool mqttSettingsEnabled: false

View File

@ -151,7 +151,7 @@ Drawer {
text: qsTr("Magic")
iconName: "../images/magic.svg"
progressive: false
visible: root.currentEngine && root.currentEngine.jsonRpcClient.currentHost && root.currentEngine.jsonRpcClient.connected
visible: root.currentEngine && root.currentEngine.jsonRpcClient.currentHost && root.currentEngine.jsonRpcClient.connected && Configuration.magicEnabled
onClicked: {
root.openMagicSettings();
root.close();