3 import
QtQuick.Controls.Material 2.3
31 property SettingsViewModel viewModel: null
45 property bool fullClose:
false 58 function closeAction() {
59 return !fullClose && _settingsStack.closeAction();
73 Layout.fillWidth:
true 74 Layout.fillHeight:
true 81 text: qsTr(
"Settings")
82 visible: !_searchField.visible
87 horizontalAlignment:
Qt.AlignLeft
88 verticalAlignment:
Qt.AlignVCenter
89 anchors.right: parent.right
90 anchors.verticalCenter: parent.verticalCenter
91 height: Math.min(implicitHeight, parent.height)
98 visible: _builder.allowSearch
99 text: qsTr(
"Search in settings")
100 onClicked: toggleSearchState()
105 visible: _builder.allowRestore
106 icon.source:
"qrc:/de/skycoder42/qtmvvm/quick/icons/ic_settings_backup_restore.svg" 107 text: qsTr(
"Restore settings")
108 onClicked: _builder.restoreDefaults()
117 target: _searchButton
119 icon.source:
"qrc:/de/skycoder42/qtmvvm/quick/icons/ic_search.svg" 132 script: _searchField.clear();
138 target: _searchButton
139 icon.name:
"gtk-close" 140 icon.source:
"qrc:/de/skycoder42/qtmvvm/quick/icons/ic_close.svg" 149 width: _labelContainer.width
153 script: _searchField.forceActiveFocus();
161 SequentialAnimation {
171 easing.type: Easing.InOutCubic
183 SequentialAnimation {
193 easing.type: Easing.InOutCubic
207 function toggleSearchState() {
220 function closeAction() {
221 if(_settingsStack.depth <= 1)
224 _settingsStack.pop();
231 id: _overviewComponent
237 Component.onCompleted: _settingsStack.push(__ovListView)
242 id: _sectionViewComponent
248 Component.onCompleted: _settingsStack.push(__secListView)
254 buildView: _settingsView
255 viewModel: _settingsView.viewModel
256 filterText: _searchField.text
258 onPresentOverview: _overviewComponent.incubateObject(_settingsStack, {
260 showSections: hasSections
262 onPresentSection: _sectionViewComponent.incubateObject(_settingsStack, {
267 _settingsView.fullClose =
true;
A ProgressBar with automatic bindings to the presenters view loading progress.
The QML import for the QtMvvmCore QML module.
static void popView()
Pops the current top level view.
The QML import for the QtMvvmQuick QML module.
A QML singleton to access common presenter methods globally.