forked from qt-creator/qt-creator
QmlDesigner.PropertyEditor: Hide action indidactors on controls
Task-number: QDS-1688 Change-Id: Ia96a8d5229b42d9ac0be75273cadfc35b5cef334 Reviewed-by: Brook Cronin <brook.cronin@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
committed by
Tim Jenssen
parent
20e95f2f19
commit
1290e07819
@@ -140,7 +140,7 @@ SectionLayout {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
actionIndicator.visible: true
|
||||
|
||||
labelColor: horizontalAlignmentComboBox.currentIndex === 0 ? colorLogic.__defaultTextColor : colorLogic.__changedTextColor
|
||||
@@ -176,7 +176,7 @@ SectionLayout {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
actionIndicator.visible: true
|
||||
|
||||
labelColor: verticalAlignmentComboBox.currentIndex === 0 ? colorLogic.__defaultTextColor : colorLogic.__changedTextColor
|
||||
|
@@ -93,6 +93,7 @@ Row {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
StudioControls.ButtonGroup {
|
||||
id: group
|
||||
|
@@ -93,6 +93,7 @@ Row {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
StudioControls.ButtonGroup {
|
||||
id: group
|
||||
|
@@ -87,4 +87,5 @@ StudioControls.Button {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
}
|
||||
|
@@ -40,6 +40,7 @@ StudioControls.CheckBox {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
labelColor: colorLogic.textColor
|
||||
ColorLogic {
|
||||
|
@@ -57,6 +57,7 @@ StudioControls.ComboBox {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
actionIndicator.visible: comboBox.showExtendedFunctionButton
|
||||
|
||||
|
@@ -42,6 +42,8 @@ Item {
|
||||
|
||||
signal reseted
|
||||
|
||||
property bool menuVisible: false
|
||||
|
||||
function show() {
|
||||
menuLoader.show()
|
||||
}
|
||||
@@ -97,6 +99,10 @@ Item {
|
||||
onAboutToShow: {
|
||||
exportMenuItem.checked = backendValue.hasPropertyAlias()
|
||||
exportMenuItem.enabled = !backendValue.isAttachedProperty()
|
||||
extendedFunctionButton.menuVisible = true
|
||||
}
|
||||
onAboutToHide: {
|
||||
extendedFunctionButton.menuVisible = false
|
||||
}
|
||||
|
||||
StudioControls.MenuItem {
|
||||
|
@@ -81,6 +81,7 @@ StudioControls.ComboBox {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
property bool showExtendedFunctionButton: true
|
||||
|
||||
|
@@ -70,6 +70,7 @@ StudioControls.TextField {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
ColorLogic {
|
||||
id: colorLogic
|
||||
|
@@ -84,6 +84,8 @@ Item {
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
ColorLogic {
|
||||
id: colorLogic
|
||||
backendValue: spinBox.backendValue
|
||||
|
@@ -53,6 +53,7 @@ RowLayout {
|
||||
actionIndicator.icon.color: extFuncLogic.color
|
||||
actionIndicator.icon.text: extFuncLogic.glyph
|
||||
actionIndicator.onClicked: extFuncLogic.show()
|
||||
actionIndicator.forceVisible: extFuncLogic.menuVisible
|
||||
|
||||
ExtendedFunctionLogic {
|
||||
id: extFuncLogic
|
||||
|
@@ -37,6 +37,7 @@ Rectangle {
|
||||
|
||||
property bool hover: false
|
||||
property bool pressed: false
|
||||
property bool forceVisible: false
|
||||
|
||||
color: actionIndicator.showBackground ? StudioTheme.Values.themeControlBackground : "transparent"
|
||||
border.color: actionIndicator.showBackground ? StudioTheme.Values.themeControlOutline : "transparent"
|
||||
@@ -50,6 +51,7 @@ Rectangle {
|
||||
id: actionIndicatorIcon
|
||||
anchors.fill: parent
|
||||
text: StudioTheme.Constants.actionIcon
|
||||
visible: text != StudioTheme.Constants.actionIcon || actionIndicator.forceVisible
|
||||
color: StudioTheme.Values.themeTextColor
|
||||
font.family: StudioTheme.Constants.iconFont.family
|
||||
font.pixelSize: StudioTheme.Values.myIconFontSize
|
||||
@@ -65,6 +67,7 @@ Rectangle {
|
||||
PropertyChanges {
|
||||
target: actionIndicatorIcon
|
||||
scale: 1.2
|
||||
visible: true
|
||||
}
|
||||
},
|
||||
State {
|
||||
|
Reference in New Issue
Block a user