Remove style from settingview

This commit is contained in:
Jaime van Kessel 2022-01-04 10:30:07 +01:00
parent 2aa931cbca
commit 722f928d12

View file

@ -2,9 +2,7 @@
// Cura is released under the terms of the LGPLv3 or higher. // Cura is released under the terms of the LGPLv3 or higher.
import QtQuick 2.7 import QtQuick 2.7
import QtQuick.Controls 1.1 import QtQuick.Controls 2.1
import QtQuick.Controls.Styles 1.1
import QtQuick.Layouts 1.2
import UM 1.2 as UM import UM 1.2 as UM
import Cura 1.0 as Cura import Cura 1.0 as Cura
@ -16,7 +14,7 @@ Item
id: settingsView id: settingsView
property QtObject settingVisibilityPresetsModel: CuraApplication.getSettingVisibilityPresetsModel() property QtObject settingVisibilityPresetsModel: CuraApplication.getSettingVisibilityPresetsModel()
property Action configureSettings //property Action configureSettings
property bool findingSettings property bool findingSettings
Item Item
@ -181,14 +179,15 @@ Item
// Mouse area that gathers the scroll events to not propagate it to the main view. // Mouse area that gathers the scroll events to not propagate it to the main view.
MouseArea MouseArea
{ {
anchors.fill: scrollView anchors.fill: contents
acceptedButtons: Qt.AllButtons acceptedButtons: Qt.AllButtons
onWheel: wheel.accepted = true onWheel: wheel.accepted = true
} }
ScrollView ListView
{ {
id: scrollView id: contents
anchors anchors
{ {
top: filterContainer.bottom top: filterContainer.bottom
@ -197,14 +196,7 @@ Item
right: parent.right right: parent.right
left: parent.left left: parent.left
} }
clip: true
style: UM.Theme.styles.scrollview
flickableItem.flickableDirection: Flickable.VerticalFlick
__wheelAreaScrollSpeed: 75 // Scroll three lines in one scroll event
ListView
{
id: contents
cacheBuffer: 1000000 // Set a large cache to effectively just cache every list item. cacheBuffer: 1000000 // Set a large cache to effectively just cache every list item.
model: UM.SettingDefinitionsModel model: UM.SettingDefinitionsModel
@ -233,7 +225,7 @@ Item
{ {
id: delegate id: delegate
width: scrollView.width width: contents.width
height: enabled ? contents.delegateHeight: 0 height: enabled ? contents.delegateHeight: 0
Behavior on height { NumberAnimation { duration: 100 } } Behavior on height { NumberAnimation { duration: 100 } }
opacity: enabled ? 1 : 0 opacity: enabled ? 1 : 0
@ -461,7 +453,7 @@ Item
MenuItem MenuItem
{ {
text: model.name text: model.name
iconName: model.icon_name //iconName: model.icon_name
onTriggered: onTriggered:
{ {
customMenuItems.model.callMenuItemMethod(name, model.actions, {"key": contextMenu.key}) customMenuItems.model.callMenuItemMethod(name, model.actions, {"key": contextMenu.key})
@ -533,4 +525,3 @@ Item
} }
} }
} }
}