3.3.1 for Unix

Ned Konz ned at bike-nomad.com
Sun Jun 9 14:52:04 UTC 2002


On Sunday 09 June 2002 07:11 am, Ned Konz wrote:

> (3) I ran Squeak from the command line in a terminal (not in the
> background). I then went to that window and drag-selected some text
> (to paste into this message). Squeak quit with the following
> complaint:
>
> $ squeak Squeak3.2gamma-4881.image
> X Error of failed request:  BadWindow (invalid Window parameter)
>   Major opcode of failed request:  25 (X_SendEvent)
>   Resource id in failed request:  0xde
>   Serial number of failed request:  12151
>   Current serial number in output stream:  12151

OK, this only happens AFTER you have done an Alt-C (copy to clipboard) 
in Squeak.

And it does this when I copy to the clipboard from any other 
application.

So perhaps it has to do with losing the X selection.

If I insert a break after the 'case SelectionClear:' around line 1153 
(so it doesn't fall through into 'case SelectionRequest') this 
doesn't happen.

However, I (often but not always) get a beep on the first Alt-C that I 
do in Squeak. The text seems to always get put in the clipboard, 
however.

These changes seem to fix both the ctrl-arrow wheel problem and the 
crash on losing the selection:

$ diff -u sqXWindow.c.sav sqXWindow.c
--- sqXWindow.c.sav     Thu Jun  6 14:28:02 2002
+++ sqXWindow.c Sun Jun  9 07:51:23 2002
@@ -1097,6 +1097,7 @@
        case 4: case 5: /* mouse wheel */
          {
            int keyCode= evt->xbutton.button + 26;      /* up/down */
+           modifierState |= CtrlKeyBit;
            recordKeyboardEvent(keyCode, EventKeyDown);
            recordKeyboardEvent(keyCode, EventKeyChar);
            recordKeyboardEvent(keyCode, EventKeyUp);
@@ -1154,6 +1155,7 @@
        stOwnsClipboard= 0;
       else if (evt->xselectionclear.selection == XA_PRIMARY)
        stOwnsSelection= 0;
+      break;   /* NK: added */

     case SelectionRequest:
       sendSelection(&evt->xselectionrequest);


-- 
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE




More information about the Squeak-dev mailing list