libsdl-1.2.15-resizing.patch 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. --- src/video/x11/SDL_x11events.c.orig Mon Feb 20 23:51:08 2012 -0500
  2. +++ src/video/x11/SDL_x11events.c Mon Mar 26 12:26:52 2012 +1300
  3. @@ -57,12 +57,6 @@
  4. static SDLKey MISC_keymap[256];
  5. SDLKey X11_TranslateKeycode(Display *display, KeyCode kc);
  6. -/*
  7. - Pending resize target for ConfigureNotify (so outdated events don't
  8. - cause inappropriate resize events)
  9. -*/
  10. -int X11_PendingConfigureNotifyWidth = -1;
  11. -int X11_PendingConfigureNotifyHeight = -1;
  12. #ifdef X_HAVE_UTF8_STRING
  13. Uint32 Utf8ToUcs4(const Uint8 *utf8)
  14. @@ -825,16 +819,6 @@
  15. #ifdef DEBUG_XEVENTS
  16. printf("ConfigureNotify! (resize: %dx%d)\n", xevent.xconfigure.width, xevent.xconfigure.height);
  17. #endif
  18. - if ((X11_PendingConfigureNotifyWidth != -1) &&
  19. - (X11_PendingConfigureNotifyHeight != -1)) {
  20. - if ((xevent.xconfigure.width != X11_PendingConfigureNotifyWidth) &&
  21. - (xevent.xconfigure.height != X11_PendingConfigureNotifyHeight)) {
  22. - /* Event is from before the resize, so ignore. */
  23. - break;
  24. - }
  25. - X11_PendingConfigureNotifyWidth = -1;
  26. - X11_PendingConfigureNotifyHeight = -1;
  27. - }
  28. if ( SDL_VideoSurface ) {
  29. if ((xevent.xconfigure.width != SDL_VideoSurface->w) ||
  30. (xevent.xconfigure.height != SDL_VideoSurface->h)) {
  31. diff -r c787fb1b5699 src/video/x11/SDL_x11events_c.h
  32. --- src/video/x11/SDL_x11events_c.h.orig Mon Feb 20 23:51:08 2012 -0500
  33. +++ src/video/x11/SDL_x11events_c.h Mon Mar 26 12:26:52 2012 +1300
  34. @@ -27,8 +27,3 @@
  35. extern void X11_InitOSKeymap(_THIS);
  36. extern void X11_PumpEvents(_THIS);
  37. extern void X11_SetKeyboardState(Display *display, const char *key_vec);
  38. -
  39. -/* Variables to be exported */
  40. -extern int X11_PendingConfigureNotifyWidth;
  41. -extern int X11_PendingConfigureNotifyHeight;
  42. -
  43. diff -r c787fb1b5699 src/video/x11/SDL_x11video.c
  44. --- src/video/x11/SDL_x11video.c.orig Mon Feb 20 23:51:08 2012 -0500
  45. +++ src/video/x11/SDL_x11video.c Mon Mar 26 12:26:52 2012 +1300
  46. @@ -1182,8 +1182,6 @@
  47. current = NULL;
  48. goto done;
  49. }
  50. - X11_PendingConfigureNotifyWidth = width;
  51. - X11_PendingConfigureNotifyHeight = height;
  52. } else {
  53. if (X11_CreateWindow(this,current,width,height,bpp,flags) < 0) {
  54. current = NULL;