diff --git a/plasmoid/contents/ui/TaskDelegate.qml b/plasmoid/contents/ui/TaskDelegate.qml index 0d96571c6..d66de8b9a 100644 --- a/plasmoid/contents/ui/TaskDelegate.qml +++ b/plasmoid/contents/ui/TaskDelegate.qml @@ -675,7 +675,7 @@ MouseArea{ if ((windowsPreviewDlg.visualParent === mainItemContainer)&&(windowsPreviewDlg.visible)) { windowsPreviewDlg.hide(); } else { - preparePreviewWindow(); + preparePreviewWindow(false); windowsPreviewDlg.show(); } } @@ -733,12 +733,14 @@ MouseArea{ ///// Helper functions ///// - function preparePreviewWindow(){ + function preparePreviewWindow(hideClose){ windowsPreviewDlg.visualParent = mainItemContainer; toolTipDelegate.parentTask = mainItemContainer; toolTipDelegate.parentIndex = itemIndex; + toolTipDelegate.hideCloseButtons = hideClose; + toolTipDelegate.appName = Qt.binding(function() { return model.AppName; }); @@ -867,7 +869,7 @@ MouseArea{ function slotShowPreviewForTasks(group) { if (group === mainItemContainer) { - preparePreviewWindow(); + preparePreviewWindow(true); windowsPreviewDlg.show(); } } @@ -1031,7 +1033,7 @@ MouseArea{ onTriggered: { if(mainItemContainer.containsMouse){ // console.log("Hovered Timer...."); - mainItemContainer.preparePreviewWindow(); + mainItemContainer.preparePreviewWindow(false); windowsPreviewDlg.show(); //windowsPreviewDlg.visible = true; } diff --git a/plasmoid/contents/ui/ToolTipDelegate2.qml b/plasmoid/contents/ui/ToolTipDelegate2.qml index ab468e3be..4ac1e2ac4 100644 --- a/plasmoid/contents/ui/ToolTipDelegate2.qml +++ b/plasmoid/contents/ui/ToolTipDelegate2.qml @@ -42,6 +42,7 @@ PlasmaExtras.ScrollArea { property string appName property int pidParent property bool isGroup + property bool hideCloseButtons property var windows readonly property bool isWin: windows !== undefined diff --git a/plasmoid/contents/ui/ToolTipInstance.qml b/plasmoid/contents/ui/ToolTipInstance.qml index 87bf0a0a5..ffad76b65 100644 --- a/plasmoid/contents/ui/ToolTipInstance.qml +++ b/plasmoid/contents/ui/ToolTipInstance.qml @@ -139,7 +139,7 @@ Column { height: units.iconSizes.smallMedium width: height - visible: isWin + visible: isWin && !hideCloseButtons acceptedButtons: Qt.LeftButton hoverEnabled: true