X11: generate clipboard update events (thanks, "chw"!).
Partially fixes Bugzilla #2266. --HG-- extra : histedit_source : 24ea05997ba9f2b128108100786937281d594cc5
This commit is contained in:
parent
a7d766c672
commit
85539b2b2d
1 changed files with 10 additions and 0 deletions
|
@ -1219,6 +1219,16 @@ X11_DispatchEvent(_THIS)
|
|||
}
|
||||
break;
|
||||
|
||||
case SelectionClear: {
|
||||
Atom XA_CLIPBOARD = X11_XInternAtom(display, "CLIPBOARD", 0);
|
||||
|
||||
if (xevent.xselectionclear.selection == XA_PRIMARY ||
|
||||
(XA_CLIPBOARD != None && xevent.xselectionclear.selection == XA_CLIPBOARD)) {
|
||||
SDL_SendClipboardUpdate();
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
default:{
|
||||
#ifdef DEBUG_XEVENTS
|
||||
printf("window %p: Unhandled event %d\n", data, xevent.type);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue