16 lines
432 B
Python
16 lines
432 B
Python
|
"""
|
||
|
This module contains a child class of QWebView in order to reimplement the wheelEvent event handler.
|
||
|
"""
|
||
|
from PyQt4 import QtCore, QtWebKit
|
||
|
|
||
|
class CWebView(QtWebKit.QWebView):
|
||
|
"""
|
||
|
This is a reimplementation of QWebView in order to override the wheelEvent method.
|
||
|
"""
|
||
|
onScroll = QtCore.pyqtSignal()
|
||
|
|
||
|
def wheelEvent(self, event):
|
||
|
self.onScroll.emit()
|
||
|
QtWebKit.QWebView.wheelEvent(self, event)
|
||
|
|