Can't receive WM_MOUSEWHEEL event in npapi windowless plugin

196 views Asked by At

I've written a windowless NPAPI plugin and I want to handle mouse events in NPP_HandleEvent().

I can get WM_PAINT, WM_LBUTTONDOWN, WM_LBUTTONUP, and WM_MOUSEMOVE event without any problem.

However, it's wired that I can't receive any WM_MOUSEWHEEL event.

uint16_t CWinLessPlugin::HandleEvent(void *event)
{
    NPEvent *pevent = (NPEvent *) event;

    switch (pevent->event)
    {   
    case WM_PAINT:
         break;
    case WM_MOUSEMOVE:
         HandleIt();
         break;
    case WM_MOUSEWHEEL:
         //never 
         break;
    }
    return 1;
 }

I really can't figure out why :(. Any help will be very appreciated.

chrome version : 31.0.1650.63

firefox version : 25.0.1

2

There are 2 answers

0
Georg Fritzsche On BEST ANSWER

WM_MOUSEWHEEL is not included in the list of (supported) events in the documentation. Firefox definitely doesn't support it [1] [2], Chrome probably doesn't either.

0
malat On

I reported that as a bug in firefox, let's see if mouse wheel event will be supported in a browser post 2014.

link: