forked from qt-creator/qt-creator
QmlDesigner: Disable scrolling when context menu is open
Disable components and assets views scrolling when the context menu is open. Fixes: QDS-6317 Change-Id: Ibdbf29b14d0383fd2b876c655ccb17c35fdb6aff Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io> Reviewed-by: Samuel Ghinet <samuel.ghinet@qt.io>
This commit is contained in:
@@ -424,7 +424,7 @@ Item {
|
|||||||
width: parent.width
|
width: parent.width
|
||||||
height: parent.height - y
|
height: parent.height - y
|
||||||
clip: true
|
clip: true
|
||||||
interactive: assetsView.verticalScrollBarVisible
|
interactive: assetsView.verticalScrollBarVisible && !contextMenu.opened
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
Repeater {
|
Repeater {
|
||||||
|
@@ -246,6 +246,7 @@ Item {
|
|||||||
id: verticalScrollView
|
id: verticalScrollView
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
clip: true
|
clip: true
|
||||||
|
interactive: !itemContextMenu.opened && !moduleContextMenu.opened
|
||||||
|
|
||||||
onContentHeightChanged: {
|
onContentHeightChanged: {
|
||||||
var maxPosition = Math.max(contentHeight - verticalScrollView.height, 0)
|
var maxPosition = Math.max(contentHeight - verticalScrollView.height, 0)
|
||||||
@@ -362,6 +363,7 @@ Item {
|
|||||||
width: 270
|
width: 270
|
||||||
height: parent.height
|
height: parent.height
|
||||||
clip: true
|
clip: true
|
||||||
|
interactive: !itemContextMenu.opened && !moduleContextMenu.opened
|
||||||
|
|
||||||
onContentHeightChanged: {
|
onContentHeightChanged: {
|
||||||
var maxPosition = Math.max(contentHeight - horizontalScrollView.height, 0)
|
var maxPosition = Math.max(contentHeight - horizontalScrollView.height, 0)
|
||||||
|
Reference in New Issue
Block a user