pdfSetMouseWheelCbk
Set a callback function for mouse wheel events.
void pdfSetMouseWheelCbk(PDFViewerHandle viewer,
void (*cbk)(void *data, int distance),
void *data)
This function sets a callback which will be called when the user
rotates the mouse wheel.
The function will be called with two arguments:
data
: the value of thedata
argument that was passed topdfSetMouseWheelCbk
distance
: the amount the mouse wheel was rotated - by default,distance
= 120 for "up" or -120 for "down"
C:
void mouseWheelCbk(void *data, int distance) {
Context *myContext = (Context *)data;
/* the mouse wheel was rotated ... */
}
...
pdfSetMouseWheelCbk(viewer, &mouseWheelCbk, &myContext);