highgui: wayland: double-buffering enabled

Also fix a weird bug that key events aren't handled.
We mustn't invoke another dispatch() while in main loop
 (while dispatching)
Merge branch 'wl_double_buffered' into wayland