forked from qt-creator/qt-creator
QmlDesigner: Add a default validator to ItemFilterComboBox
Change-Id: Iba8f3f42d7028bc5da5b5abd6d3581f67184376b Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
This commit is contained in:
@@ -49,7 +49,6 @@ Section {
|
|||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
width: implicitWidth
|
width: implicitWidth
|
||||||
typeFilter: "QtQuick.AudioOutput"
|
typeFilter: "QtQuick.AudioOutput"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.audioOutput
|
backendValue: backendValues.audioOutput
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -70,7 +69,6 @@ Section {
|
|||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
width: implicitWidth
|
width: implicitWidth
|
||||||
typeFilter: "QtQuick.VideoOutput"
|
typeFilter: "QtQuick.VideoOutput"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.videoOutput
|
backendValue: backendValues.videoOutput
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -23,7 +23,6 @@ Section {
|
|||||||
SecondColumnLayout {
|
SecondColumnLayout {
|
||||||
ItemFilterComboBox {
|
ItemFilterComboBox {
|
||||||
typeFilter: "QtQuick.QtObject"
|
typeFilter: "QtQuick.QtObject"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.target
|
backendValue: backendValues.target
|
||||||
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
|
@@ -52,7 +52,6 @@ Section {
|
|||||||
SecondColumnLayout {
|
SecondColumnLayout {
|
||||||
ItemFilterComboBox {
|
ItemFilterComboBox {
|
||||||
typeFilter: "QtQuick.Item"
|
typeFilter: "QtQuick.Item"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.target
|
backendValue: backendValues.target
|
||||||
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
|
@@ -100,7 +100,6 @@ Section {
|
|||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
width: implicitWidth
|
width: implicitWidth
|
||||||
typeFilter: "QtQuick.Item"
|
typeFilter: "QtQuick.Item"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.layer_effect
|
backendValue: backendValues.layer_effect
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -55,7 +55,6 @@ Column {
|
|||||||
SecondColumnLayout {
|
SecondColumnLayout {
|
||||||
ItemFilterComboBox {
|
ItemFilterComboBox {
|
||||||
typeFilter: "Component"
|
typeFilter: "Component"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.sourceComponent
|
backendValue: backendValues.sourceComponent
|
||||||
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
|
@@ -181,7 +181,6 @@ Column {
|
|||||||
SecondColumnLayout {
|
SecondColumnLayout {
|
||||||
ItemFilterComboBox {
|
ItemFilterComboBox {
|
||||||
typeFilter: "QtQuick.QtObject"
|
typeFilter: "QtQuick.QtObject"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.drag_target
|
backendValue: backendValues.drag_target
|
||||||
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
|
@@ -42,7 +42,6 @@ Column {
|
|||||||
SecondColumnLayout {
|
SecondColumnLayout {
|
||||||
ItemFilterComboBox {
|
ItemFilterComboBox {
|
||||||
typeFilter: "Component"
|
typeFilter: "Component"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.delegate
|
backendValue: backendValues.delegate
|
||||||
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
|
@@ -55,7 +55,6 @@ Section {
|
|||||||
SecondColumnLayout {
|
SecondColumnLayout {
|
||||||
ItemFilterComboBox {
|
ItemFilterComboBox {
|
||||||
typeFilter: "QtMultimedia.AudioDevice"
|
typeFilter: "QtMultimedia.AudioDevice"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: backendValues.outputDevice
|
backendValue: backendValues.outputDevice
|
||||||
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
|
@@ -266,7 +266,6 @@ Section {
|
|||||||
|
|
||||||
ItemFilterComboBox {
|
ItemFilterComboBox {
|
||||||
typeFilter: "QtQuick3D.TextureInput"
|
typeFilter: "QtQuick3D.TextureInput"
|
||||||
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
|
||||||
backendValue: layoutTextureInput.backendValue
|
backendValue: layoutTextureInput.backendValue
|
||||||
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
implicitWidth: StudioTheme.Values.singleControlColumnWidth
|
||||||
+ StudioTheme.Values.actionIndicatorWidth
|
+ StudioTheme.Values.actionIndicatorWidth
|
||||||
|
@@ -13,6 +13,8 @@ HelperWidgets.ComboBox {
|
|||||||
editable: true
|
editable: true
|
||||||
model: comboBox.addDefaultItem(itemFilterModel.itemModel)
|
model: comboBox.addDefaultItem(itemFilterModel.itemModel)
|
||||||
|
|
||||||
|
validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
|
||||||
|
|
||||||
HelperWidgets.ItemFilterModel {
|
HelperWidgets.ItemFilterModel {
|
||||||
id: itemFilterModel
|
id: itemFilterModel
|
||||||
modelNodeBackendProperty: modelNodeBackend
|
modelNodeBackendProperty: modelNodeBackend
|
||||||
|
Reference in New Issue
Block a user