diff --git a/applet/contents/ui/ConnectionItem.qml b/applet/contents/ui/ConnectionItem.qml --- a/applet/contents/ui/ConnectionItem.qml +++ b/applet/contents/ui/ConnectionItem.qml @@ -118,36 +118,42 @@ onClicked: changeState() } - } - PlasmaCore.SvgItem { - id: separator - height: lineSvg.elementSize("horizontal-line").height - Layout.fillWidth: true - Layout.maximumHeight: height - elementId: "horizontal-line" - svg: PlasmaCore.Svg { id: lineSvg; imagePath: "widgets/line" } - visible: connectionItem.expanded - opacity: visible + MouseArea { + acceptedButtons: Qt.RightButton + Layout.alignment: Qt.AlignTop | Qt.AlignLeft + width: parent.width + height: parent.height + onPressed: { + contextMenu.visualParent = parent + contextMenu.open(mouse.x, mouse.y) + } + } } - Loader { - id: expandableComponentLoader + ColumnLayout { Layout.fillHeight: true - Layout.fillWidth: true - height: childrenRect.height - } - } + PlasmaCore.SvgItem { + id: separator + height: lineSvg.elementSize("horizontal-line").height + Layout.fillWidth: true + Layout.maximumHeight: height + elementId: "horizontal-line" + svg: PlasmaCore.Svg { id: lineSvg; imagePath: "widgets/line" } + visible: connectionItem.expanded + opacity: visible + } - MouseArea { - acceptedButtons: Qt.RightButton - anchors.fill: parent - onPressed: { - contextMenu.visualParent = parent - contextMenu.open() + Loader { + id: expandableComponentLoader + Layout.fillHeight: true + Layout.fillWidth: true + height: childrenRect.height + } } } + PlasmaComponents.Menu { id: contextMenu PlasmaComponents.MenuItem {