diff options
author | Andrea Diamantini <adjam7@gmail.com> | 2009-10-25 11:10:35 +0100 |
---|---|---|
committer | Andrea Diamantini <adjam7@gmail.com> | 2009-10-25 11:10:35 +0100 |
commit | e0fa463ebb64c671a92862da600df70c8b76e0cc (patch) | |
tree | 9a4a3fa4b2861768e5ce8f834978bb8ab308a69b /src/webview.cpp | |
parent | Just close tab on middle mouse click (diff) | |
parent | A better popup implementation (diff) | |
download | rekonq-e0fa463ebb64c671a92862da600df70c8b76e0cc.tar.xz |
Merge commit 'refs/merge-requests/1902' of git://gitorious.org/rekonq/mainline into Lasts1
Diffstat (limited to 'src/webview.cpp')
-rw-r--r-- | src/webview.cpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/webview.cpp b/src/webview.cpp index 7efded7f..edd8d9f6 100644 --- a/src/webview.cpp +++ b/src/webview.cpp @@ -63,6 +63,7 @@ WebView::WebView(QWidget* parent) , m_scrollDirection(WebView::NoScroll) , m_scrollSpeedVertical(0) , m_scrollSpeedHorizontal(0) + , m_mousePos(QPoint(0,0)) { setPage(m_page); @@ -451,22 +452,19 @@ void WebView::mousePressEvent(QMouseEvent *event) void WebView::mouseMoveEvent(QMouseEvent *event) { - QPoint p = event->pos(); - QSize s = size(); - int x = s.width() / 2; - int y = s.height() - 30; // quite reasonable value, without performing requests, cause of speed + m_mousePos = event->pos(); - if(p.x() <= x && p.y() >= y ) - Application::instance()->mainWindow()->setFlickeringZone(true); - else - Application::instance()->mainWindow()->setFlickeringZone(false); - if( url().protocol() != "rekonq" ) { QWebView::mouseMoveEvent(event); } } +QPoint WebView::mousePos() +{ + return m_mousePos; +} + void WebView::wheelEvent(QWheelEvent *event) { |