Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion panels/dock/AppletItemBackground.qml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,13 @@ import QtQuick.Controls
import org.deepin.ds.dock 1.0
import org.deepin.dtk

Item {
MouseArea {
id: control
property bool isActive
property real radius: 4

// can accept mouse event,prevent further event delivery
acceptedButtons: Qt.LeftButton | Qt.RightButton
implicitWidth: 24
implicitHeight: 24
property Palette backgroundColor: Palette {
Expand Down
33 changes: 18 additions & 15 deletions panels/dock/tray/package/ActionShowStashDelegate.qml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ AppletItemButton {

padding: itemPadding

D.ColorSelector.hovered: (isDropHover && DDT.TraySortOrderModel.actionsAlwaysVisible) || hoverHandler.hovered || stashedPopup.popupVisible
D.ColorSelector.hovered: (isDropHover && DDT.TraySortOrderModel.actionsAlwaysVisible) || hovered || stashedPopup.popupVisible

property var itemGlobalPoint: {
var a = root
Expand Down Expand Up @@ -95,11 +95,11 @@ AppletItemButton {

onClicked: {
if (stashedPopup.popupVisible) {
stashedPopup.close();
stashedPopup.close()
} else {
stashedPopup.open();
stashedPopup.open()
}
toolTip.close();
toolTip.close()
}

PanelToolTip {
Expand All @@ -117,18 +117,21 @@ AppletItemButton {
toolTip.open()
}
}
HoverHandler {
id: hoverHandler
onHoveredChanged: {
if (hovered) {
toolTipShowTimer.start()
} else {
if (toolTipShowTimer.running) {
toolTipShowTimer.stop()
}

toolTip.close()

onHoveredChanged: {
if (stashedPopup.popupVisible) {
return
}

if (hovered) {
toolTipShowTimer.start()
} else {
if (toolTipShowTimer.running) {
toolTipShowTimer.stop()
}

toolTip.close()
}
}

}
20 changes: 9 additions & 11 deletions panels/dock/tray/package/ActionToggleCollapseDelegate.qml
Original file line number Diff line number Diff line change
Expand Up @@ -64,19 +64,17 @@ AppletItemButton {
toolTip.open()
}
}
HoverHandler {
id: hoverHandler
enabled: root.inputEventsEnabled
onHoveredChanged: {
if (hovered) {
toolTipShowTimer.start()
} else {
if (toolTipShowTimer.running) {
toolTipShowTimer.stop()
}

toolTip.close()

onHoveredChanged: {
if (hovered) {
toolTipShowTimer.start()
} else {
if (toolTipShowTimer.running) {
toolTipShowTimer.stop()
}

toolTip.close()
}
}
}