improved context menu handling
svn path=/branches/KDE/4.2/kdelibs/; revision=919700
This commit is contained in:
parent
930eaad353
commit
5171e27826
@ -232,9 +232,16 @@ void WebView::contextMenuEvent(QGraphicsSceneContextMenuEvent *event)
|
||||
|
||||
QContextMenuEvent ce(static_cast<QContextMenuEvent::Reason>(event->reason()),
|
||||
event->pos().toPoint(), event->screenPos());
|
||||
d->page->event(&ce);
|
||||
if (ce.isAccepted()) {
|
||||
|
||||
if (d->page->swallowContextMenuEvent(&ce)) {
|
||||
event->accept();
|
||||
} else {
|
||||
d->page->updatePositionDependentActions(event->pos().toPoint());
|
||||
|
||||
d->page->event(&ce);
|
||||
if (ce.isAccepted()) {
|
||||
event->accept();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user