Allow toggling the collapse state of extender items by double clicking the drag handle.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=875202
This commit is contained in:
parent
1a63cf107a
commit
32fa54a46d
@ -623,6 +623,13 @@ void ExtenderItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ExtenderItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event)
|
||||||
|
{
|
||||||
|
if (d->titleRect().contains(event->pos())) {
|
||||||
|
d->toggleCollapse();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void ExtenderItem::hoverMoveEvent(QGraphicsSceneHoverEvent *event)
|
void ExtenderItem::hoverMoveEvent(QGraphicsSceneHoverEvent *event)
|
||||||
{
|
{
|
||||||
if (d->titleRect().contains(event->pos())) {
|
if (d->titleRect().contains(event->pos())) {
|
||||||
|
@ -199,6 +199,7 @@ class PLASMA_EXPORT ExtenderItem : public QGraphicsWidget
|
|||||||
void resizeEvent(QGraphicsSceneResizeEvent *event);
|
void resizeEvent(QGraphicsSceneResizeEvent *event);
|
||||||
|
|
||||||
void mousePressEvent(QGraphicsSceneMouseEvent *event);
|
void mousePressEvent(QGraphicsSceneMouseEvent *event);
|
||||||
|
void mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event);
|
||||||
void mouseMoveEvent(QGraphicsSceneMouseEvent *event);
|
void mouseMoveEvent(QGraphicsSceneMouseEvent *event);
|
||||||
void mouseReleaseEvent(QGraphicsSceneMouseEvent *event);
|
void mouseReleaseEvent(QGraphicsSceneMouseEvent *event);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user