ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/SheepShaver/src/Unix/video_x.cpp
(Generate patch)

Comparing SheepShaver/src/Unix/video_x.cpp (file contents):
Revision 1.8 by gbeauche, 2003-12-27T10:37:30Z vs.
Revision 1.9 by gbeauche, 2003-12-31T11:37:26Z

# Line 1 | Line 1
1   /*
2   *  video_x.cpp - Video/graphics emulation, X11 specific stuff
3   *
4 < *  SheepShaver (C) 1997-2002 Marc Hellwig and Christian Bauer
4 > *  SheepShaver (C) 1997-2003 Marc Hellwig and Christian Bauer
5   *
6   *  This program is free software; you can redistribute it and/or modify
7   *  it under the terms of the GNU General Public License as published by
# Line 135 | Line 135 | extern Display *x_display;
135   // From sys_unix.cpp
136   extern void SysMountFirstFloppy(void);
137  
138 + // From clip_unix.cpp
139 + extern void ClipboardSelectionClear(XSelectionClearEvent *);
140 + extern void ClipboardSelectionRequest(XSelectionRequestEvent *);
141 + extern void ClipboardSelectionNotify(XSelectionEvent *req);
142 +
143  
144   // Video acceleration through SIGSEGV
145   #ifdef ENABLE_VOSF
# Line 1181 | Line 1186 | static void handle_events(void)
1186          for (;;) {
1187                  XEvent event;
1188  
1189 <                if (!XCheckMaskEvent(x_display, eventmask, &event))
1189 >                if (!XCheckMaskEvent(x_display, eventmask, &event)) {
1190 >                        // Handle clipboard events
1191 >                        if (XCheckTypedEvent(x_display, SelectionRequest, &event))
1192 >                                ClipboardSelectionRequest(&event.xselectionrequest);
1193 >                        else if (XCheckTypedEvent(x_display, SelectionClear, &event))
1194 >                                ClipboardSelectionClear(&event.xselectionclear);
1195 >                        else if (XCheckTypedEvent(x_display, SelectionNotify, &event))
1196 >                                ClipboardSelectionNotify(&event.xselection);
1197                          break;
1198 +                }
1199  
1200                  switch (event.type) {
1201                          // Mouse button

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines