home *** CD-ROM | disk | FTP | other *** search
Text File | 1992-07-20 | 39.0 KB | 1,395 lines |
- Newsgroups: comp.sources.x
- Path: uunet!europa.asd.contel.com!darwin.sura.net!mips!msi!dcmartin
- From: rws@EXPO.LCS.MIT.EDU (Bob Scheifler)
- Subject: v18i035: X11R5 public fix #10, Part02/02
- Message-ID: <1992Jul20.154638.2350@msi.com>
- Originator: dcmartin@fascet
- Sender: dcmartin@msi.com (David C. Martin - Moderator)
- Organization: Molecular Simulations, Inc.
- References: <csx-18i034-X11R5-fix10@uunet.UU.NET>
- Date: Mon, 20 Jul 1992 15:46:38 GMT
- Approved: dcmartin@msi.com
- Lines: 1381
-
- Submitted-by: rws@EXPO.LCS.MIT.EDU (Bob Scheifler)
- Posting-number: Volume 18, Issue 35
- Archive-name: X11R5-fix10/part02
-
- #!/bin/sh
- # this is part.02 (part 2 of a multipart archive)
- # do not concatenate these parts, unpack them in order with /bin/sh
- # file fix-10 continued
- #
- if test ! -r _shar_seq_.tmp; then
- echo 'Please unpack part 1 first!'
- exit 1
- fi
- (read Scheck
- if test "$Scheck" != 2; then
- echo Please unpack part "$Scheck" next!
- exit 1
- else
- exit 0
- fi
- ) < _shar_seq_.tmp || exit 1
- if test ! -f _shar_wnt_.tmp; then
- echo 'x - still skipping fix-10'
- else
- echo 'x - continuing file fix-10'
- sed 's/^X//' << 'SHAR_EOF' >> 'fix-10' &&
- X sizep->flags |= PBaseSize;
- X if (w->wm.base_width == XtUnspecifiedShellInt)
- X w->wm.base_width = 0;
- --- 1104,1112 ----
- X || sizep->max_aspect.y != XtUnspecifiedShellInt) {
- X sizep->flags |= PAspect;
- X }
- ! if (sizep->flags & PBaseSize
- ! || w->wm.base_width != XtUnspecifiedShellInt
- ! || w->wm.base_height != XtUnspecifiedShellInt) {
- X sizep->flags |= PBaseSize;
- X if (w->wm.base_width == XtUnspecifiedShellInt)
- X w->wm.base_width = 0;
- ***************
- *** 1112,1124 ****
- X if (w->wm.base_height == XtUnspecifiedShellInt)
- X w->wm.base_height = 0;
- X }
- ! if (sizep->width_inc != XtUnspecifiedShellInt
- X || sizep->height_inc != XtUnspecifiedShellInt) {
- X if (sizep->width_inc < 1) sizep->width_inc = 1;
- X if (sizep->height_inc < 1) sizep->height_inc = 1;
- X sizep->flags |= PResizeInc;
- X }
- ! if (sizep->max_width != XtUnspecifiedShellInt
- X || sizep->max_height != XtUnspecifiedShellInt) {
- X sizep->flags |= PMaxSize;
- X if (sizep->max_width == XtUnspecifiedShellInt)
- --- 1113,1127 ----
- X if (w->wm.base_height == XtUnspecifiedShellInt)
- X w->wm.base_height = 0;
- X }
- ! if (sizep->flags & PResizeInc
- ! || sizep->width_inc != XtUnspecifiedShellInt
- X || sizep->height_inc != XtUnspecifiedShellInt) {
- X if (sizep->width_inc < 1) sizep->width_inc = 1;
- X if (sizep->height_inc < 1) sizep->height_inc = 1;
- X sizep->flags |= PResizeInc;
- X }
- ! if (sizep->flags & PMaxSize
- ! || sizep->max_width != XtUnspecifiedShellInt
- X || sizep->max_height != XtUnspecifiedShellInt) {
- X sizep->flags |= PMaxSize;
- X if (sizep->max_width == XtUnspecifiedShellInt)
- ***************
- *** 1126,1133 ****
- X if (sizep->max_height == XtUnspecifiedShellInt)
- X sizep->max_height = BIGSIZE;
- X }
- ! if(sizep->min_width != XtUnspecifiedShellInt
- ! || sizep->min_height != XtUnspecifiedShellInt) {
- X sizep->flags |= PMinSize;
- X if (sizep->min_width == XtUnspecifiedShellInt)
- X sizep->min_width = 1;
- --- 1129,1137 ----
- X if (sizep->max_height == XtUnspecifiedShellInt)
- X sizep->max_height = BIGSIZE;
- X }
- ! if (sizep->flags & PMinSize
- ! || sizep->min_width != XtUnspecifiedShellInt
- ! || sizep->min_height != XtUnspecifiedShellInt) {
- X sizep->flags |= PMinSize;
- X if (sizep->min_width == XtUnspecifiedShellInt)
- X sizep->min_width = 1;
- ***************
- *** 1766,1777 ****
- X _SetWMSizeHints((WMShellWidget)w);
- X }
- X
- ! if (w->shell.override_redirect) return XtGeometryDone;
- X
- X /* If no non-stacking bits are set, there's no way to tell whether
- X or not this worked, so assume it did */
- X
- ! if (!(mask & ~(CWStackMode | CWSibling))) return XtGeometryDone;
- X
- X if (wm && ((WMShellWidget)w)->wm.wait_for_wm == FALSE) {
- X /* the window manager is sick
- --- 1770,1781 ----
- X _SetWMSizeHints((WMShellWidget)w);
- X }
- X
- ! if (w->shell.override_redirect) return XtGeometryYes;
- X
- X /* If no non-stacking bits are set, there's no way to tell whether
- X or not this worked, so assume it did */
- X
- ! if (!(mask & ~(CWStackMode | CWSibling))) return XtGeometryYes;
- X
- X if (wm && ((WMShellWidget)w)->wm.wait_for_wm == FALSE) {
- X /* the window manager is sick
- ***************
- *** 1818,1824 ****
- X w->shell.client_specified |= _XtShellPositionValid;
- X }
- X else w->shell.client_specified &= ~_XtShellPositionValid;
- ! return XtGeometryDone;
- X }
- X } else if (!wm ||
- X (event.type == ClientMessage &&
- --- 1822,1828 ----
- X w->shell.client_specified |= _XtShellPositionValid;
- X }
- X else w->shell.client_specified &= ~_XtShellPositionValid;
- ! return XtGeometryYes;
- X }
- X } else if (!wm ||
- X (event.type == ClientMessage &&
- ***************
- *** 1830,1836 ****
- X w->core.x = event.xclient.data.s[0];
- X w->core.y = event.xclient.data.s[1];
- X w->shell.client_specified |= _XtShellPositionValid;
- ! return XtGeometryDone;
- X } else XtAppWarningMsg(XtWidgetToApplicationContext((Widget)w),
- X "internalError", "shell", XtCXtToolkitError,
- X "Shell's window manager interaction is broken",
- --- 1834,1840 ----
- X w->core.x = event.xclient.data.s[0];
- X w->core.y = event.xclient.data.s[1];
- X w->shell.client_specified |= _XtShellPositionValid;
- ! return XtGeometryYes;
- X } else XtAppWarningMsg(XtWidgetToApplicationContext((Widget)w),
- X "internalError", "shell", XtCXtToolkitError,
- X "Shell's window manager interaction is broken",
- ***************
- *** 1948,1956 ****
- X }
- X #undef NEQ
- X
- ! if (set_prop && nwmshell->wm.transient != owmshell->wm.transient) {
- X if (nwmshell->wm.transient) {
- X if (!XtIsTransientShell(new) &&
- X nwmshell->wm.wm_hints.window_group !=
- X XtUnspecifiedWindowGroup)
- X XSetTransientForHint(XtDisplay(new), XtWindow(new),
- --- 1952,1962 ----
- X }
- X #undef NEQ
- X
- ! if (XtIsRealized(new) &&
- ! nwmshell->wm.transient != owmshell->wm.transient) {
- X if (nwmshell->wm.transient) {
- X if (!XtIsTransientShell(new) &&
- + !nwmshell->shell.override_redirect &&
- X nwmshell->wm.wm_hints.window_group !=
- X XtUnspecifiedWindowGroup)
- X XSetTransientForHint(XtDisplay(new), XtWindow(new),
- ***************
- *** 1973,1982 ****
- X TransientShellWidget new = (TransientShellWidget)newW;
- X
- X if (XtIsRealized(newW)
- ! && ((new->transient.transient_for != old->transient.transient_for)
- ! || (new->transient.transient_for == NULL
- ! && (new->wm.wm_hints.window_group
- ! != old->wm.wm_hints.window_group)))) {
- X
- X _SetTransientForHint(new, True);
- X }
- --- 1979,1989 ----
- X TransientShellWidget new = (TransientShellWidget)newW;
- X
- X if (XtIsRealized(newW)
- ! && ((new->wm.transient && !old->wm.transient)
- ! || ((new->transient.transient_for != old->transient.transient_for)
- ! || (new->transient.transient_for == NULL
- ! && (new->wm.wm_hints.window_group
- ! != old->wm.wm_hints.window_group))))) {
- X
- X _SetTransientForHint(new, True);
- X }
- *** /tmp/,RCSt1029904 Tue Mar 17 11:40:32 1992
- --- mit/lib/Xt/Geometry.c Tue Feb 11 17:14:44 1992
- ***************
- *** 1,4 ****
- ! /* $XConsortium: Geometry.c,v 1.54 91/09/23 11:09:45 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- --- 1,4 ----
- ! /* $XConsortium: Geometry.c,v 1.55 92/02/11 17:13:18 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- ***************
- *** 68,74 ****
- X XtGeometryResult returnCode;
- X Widget parent = widget->core.parent;
- X XtGeometryMask changeMask;
- ! Boolean managed, parentRealized;
- X XWindowChanges changes;
- X
- X *clear_rect_obj = FALSE;
- --- 68,74 ----
- X XtGeometryResult returnCode;
- X Widget parent = widget->core.parent;
- X XtGeometryMask changeMask;
- ! Boolean managed, parentRealized, rgm = False;
- X XWindowChanges changes;
- X
- X *clear_rect_obj = FALSE;
- ***************
- *** 84,89 ****
- --- 84,90 ----
- X if ( ext->version == XtShellExtensionVersion
- X && ext->record_size == sizeof(ShellClassExtensionRec)) {
- X manager = ext->root_geometry_manager;
- + rgm = True;
- X } else {
- X String params[1];
- X Cardinal num_params = 1;
- ***************
- *** 215,220 ****
- --- 216,224 ----
- X }
- X
- X if (XtIsWidget(widget)) { /* reconfigure the window (if needed) */
- +
- + if (rgm) return returnCode;
- +
- X if (changes.x != widget->core.x) {
- X changeMask |= CWX;
- X changes.x = widget->core.x;
- *** /tmp/,RCSt1029924 Tue Mar 17 11:41:32 1992
- --- mit/lib/Xt/Convert.c Thu Feb 27 17:09:51 1992
- ***************
- *** 1,4 ****
- ! /* $XConsortium: Convert.c,v 1.63 91/11/26 13:54:29 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- --- 1,4 ----
- ! /* $XConsortium: Convert.c,v 1.65 92/02/27 17:08:12 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- ***************
- *** 64,70 ****
- X ConverterPtr rec;
- X int i;
- X XtCacheType cache_type;
- ! for (i = CONVERTHASHSIZE; --i >- 0; ) {
- X for (rec = *globalConverterTable++; rec; rec = rec->next) {
- X cache_type = rec->cache_type;
- X if (rec->do_ref_count)
- --- 64,70 ----
- X ConverterPtr rec;
- X int i;
- X XtCacheType cache_type;
- ! for (i = CONVERTHASHSIZE; --i >= 0; ) {
- X for (rec = *globalConverterTable++; rec; rec = rec->next) {
- X cache_type = rec->cache_type;
- X if (rec->do_ref_count)
- ***************
- *** 738,747 ****
- --- 738,755 ----
- X {
- X Heap *heap;
- X XtPointer closure = NULL;
- + unsigned int supplied_size = to->size;
- X Boolean do_ref = cP->do_ref_count && cache_ref_return;
- X Boolean do_free = False;
- X Boolean retval =
- X (*(XtTypeConverter)converter)(dpy, args, &num_args, from, to, &closure);
- +
- + if (retval == False && supplied_size < to->size) {
- + /* programmer error: caller must allocate sufficient storage */
- + *cache_ref_return = NULL;
- + return False;
- + }
- +
- X if ((cP->cache_type == XtCacheNone) || do_ref) {
- X heap = NULL;
- X do_free = True;
- *** /tmp/,RCSt1029964 Tue Mar 17 11:44:10 1992
- --- mit/lib/Xt/Event.c Fri Feb 21 15:56:45 1992
- ***************
- *** 1,4 ****
- ! /* $XConsortium: Event.c,v 1.135 91/10/25 13:19:23 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- --- 1,4 ----
- ! /* $XConsortium: Event.c,v 1.136 92/02/21 15:54:06 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- ***************
- *** 510,516 ****
- X
- X #define EHMAXSIZE 25 /* do not make whopping big */
- X
- ! static void CallEventHandlers(widget, event, mask)
- X Widget widget;
- X XEvent *event;
- X EventMask mask;
- --- 510,516 ----
- X
- X #define EHMAXSIZE 25 /* do not make whopping big */
- X
- ! static Boolean CallEventHandlers(widget, event, mask)
- X Widget widget;
- X XEvent *event;
- X EventMask mask;
- ***************
- *** 551,556 ****
- --- 551,557 ----
- X (*(proc[i]))(widget, closure[i], event, &cont_to_disp);
- X if (numprocs > EHMAXSIZE)
- X XtFree((char *)proc);
- + return cont_to_disp;
- X }
- X
- X static Region nullRegion;
- ***************
- *** 574,579 ****
- --- 575,581 ----
- X XEvent nextEvent;
- X Boolean was_dispatched = XtDidNothing;
- X Boolean call_tm = XtDidNothing;
- + Boolean cont_to_disp;
- X
- X if (XFilterEvent(event, XtWindow(widget)))
- X return XtDidFilter;
- ***************
- *** 652,657 ****
- --- 654,661 ----
- X if (widget->core.tm.translations &&
- X (mask & widget->core.tm.translations->eventMask))
- X call_tm = XtDidDispatch;
- +
- + cont_to_disp = True;
- X p=widget->core.event_table;
- X if (p) {
- X if (p->next) {
- ***************
- *** 673,682 ****
- X }
- X if (numprocs) {
- X if (p) {
- ! CallEventHandlers(widget, event, mask);
- X } else {
- X int i;
- - Boolean cont_to_disp = True;
- X for (i = 0; i < numprocs && cont_to_disp; i++)
- X (*(proc[i]))(widget, closure[i], event, &cont_to_disp);
- X }
- --- 677,685 ----
- X }
- X if (numprocs) {
- X if (p) {
- ! cont_to_disp = CallEventHandlers(widget, event, mask);
- X } else {
- X int i;
- X for (i = 0; i < numprocs && cont_to_disp; i++)
- X (*(proc[i]))(widget, closure[i], event, &cont_to_disp);
- X }
- ***************
- *** 683,694 ****
- X was_dispatched = XtDidDispatch;
- X }
- X } else if (mask & p->mask) {
- X was_dispatched = XtDidDispatch;
- - (*p->proc)(widget, p->closure, event, &was_dispatched);
- - was_dispatched = XtDidDispatch;
- X }
- X }
- ! if (call_tm)
- X _XtTranslateEvent(widget, event);
- X return (was_dispatched|call_tm);
- X }
- --- 686,696 ----
- X was_dispatched = XtDidDispatch;
- X }
- X } else if (mask & p->mask) {
- + (*p->proc)(widget, p->closure, event, &cont_to_disp);
- X was_dispatched = XtDidDispatch;
- X }
- X }
- ! if (call_tm && cont_to_disp)
- X _XtTranslateEvent(widget, event);
- X return (was_dispatched|call_tm);
- X }
- *** /tmp/,RCSt1029986 Tue Mar 17 11:45:45 1992
- --- mit/lib/Xt/TranslateI.h Mon Feb 24 17:44:54 1992
- ***************
- *** 1,4 ****
- ! /* $XConsortium: TranslateI.h,v 1.42 91/06/14 17:58:41 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- --- 1,4 ----
- ! /* $XConsortium: TranslateI.h,v 1.43 92/02/24 17:42:20 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- ***************
- *** 59,64 ****
- --- 59,65 ----
- X typedef struct _LateBindings {
- X unsigned int knot:1;
- X unsigned int pair:1;
- + unsigned short ref_count; /* garbage collection */
- X KeySym keysym;
- X } LateBindings, *LateBindingsPtr;
- X
- *** /tmp/,RCSt1000106 Tue Mar 17 11:47:21 1992
- --- mit/lib/Xt/TMparse.c Thu Mar 5 18:49:55 1992
- ***************
- *** 1,4 ****
- ! /* $XConsortium: TMparse.c,v 1.123 91/07/28 11:52:14 swick Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- --- 1,4 ----
- ! /* $XConsortium: TMparse.c,v 1.128 92/03/05 18:48:55 converse Exp $ */
- X
- X /***********************************************************
- X Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
- ***************
- *** 528,533 ****
- --- 528,535 ----
- X *lateBindings = temp;
- X temp[count].knot = notL;
- X temp[count].pair = pair;
- + if (count == 0)
- + temp[count].ref_count = 1;
- X temp[count++].keysym = keysymL;
- X if (keysymR){
- X temp[count].knot = notR;
- ***************
- *** 1012,1019 ****
- X EventPtr event;
- X Boolean* error;
- X {
- - char atomName[1000], *start;
- -
- X ScanWhitespace(str);
- X
- X if (*str == ',' || *str == ':') {
- --- 1014,1019 ----
- ***************
- *** 1021,1026 ****
- --- 1021,1027 ----
- X event->event.eventCode = 0L;
- X event->event.eventCodeMask = 0L;
- X } else {
- + char *start, atomName[1000];
- X start = str;
- X while (
- X *str != ','
- ***************
- *** 1037,1043 ****
- X bcopy(start, atomName, str-start);
- X atomName[str-start] = '\0';
- X event->event.eventCode = XrmStringToQuark(atomName);
- - event->event.eventCodeMask = ~0L;
- X event->event.matchEvent = _XtMatchAtom;
- X }
- X return str;
- --- 1038,1043 ----
- ***************
- *** 1046,1055 ****
- X static ModifierMask buttonModifierMasks[] = {
- X 0, Button1Mask, Button2Mask, Button3Mask, Button4Mask, Button5Mask
- X };
- X
- ! static String ParseEvent(str, event,error)
- X register String str;
- X EventPtr event;
- X Boolean* error;
- X {
- X Cardinal tmEvent;
- --- 1046,1058 ----
- X static ModifierMask buttonModifierMasks[] = {
- X 0, Button1Mask, Button2Mask, Button3Mask, Button4Mask, Button5Mask
- X };
- + static String ParseRepeat();
- X
- ! static String ParseEvent(str, event, reps, plus, error)
- X register String str;
- X EventPtr event;
- + int* reps;
- + Boolean* plus;
- X Boolean* error;
- X {
- X Cardinal tmEvent;
- ***************
- *** 1070,1075 ****
- --- 1073,1082 ----
- X return PanicModeRecovery(str);
- X }
- X else str++;
- + if (*str == '(') {
- + str = ParseRepeat(str, reps, plus, error);
- + if (*error) return str;
- + }
- X str = (*(events[tmEvent].parseDetail))(
- X str, events[tmEvent].closure, event,error);
- X if (*error) return str;
- ***************
- *** 1136,1141 ****
- --- 1143,1156 ----
- X return str;
- X }
- X
- +
- + static EventSeqRec timerEventRec = {
- + {0, 0, NULL, _XtEventTimerEventType, 0L, 0L, NULL},
- + /* (StatePtr) -1 */ NULL,
- + NULL,
- + NULL
- + };
- +
- X static void RepeatDown(eventP, reps, actionsP)
- X EventPtr *eventP;
- X int reps;
- ***************
- *** 1146,1158 ****
- X EventPtr upEvent = &upEventRec;
- X register int i;
- X
- - static EventSeqRec timerEventRec = {
- - {0, 0,NULL, _XtEventTimerEventType, 0L, 0L,NULL},
- - /* (StatePtr) -1 */ NULL,
- - NULL,
- - NULL
- - };
- -
- X downEvent = event = *eventP;
- X *upEvent = *downEvent;
- X upEvent->event.eventType = ((event->event.eventType == ButtonPress) ?
- --- 1161,1166 ----
- ***************
- *** 1163,1168 ****
- --- 1171,1179 ----
- X upEvent->event.modifiers
- X |= buttonModifierMasks[event->event.eventCode];
- X
- + if (event->event.lateModifiers)
- + event->event.lateModifiers->ref_count += (reps - 1) * 2;
- +
- X for (i=1; i<reps; i++) {
- X
- X /* up */
- ***************
- *** 1197,1209 ****
- X EventPtr upEvent = &upEventRec;
- X register int i;
- X
- - static EventSeqRec timerEventRec = {
- - {0, 0,NULL, _XtEventTimerEventType, 0L, 0L,NULL},
- - /* (StatePtr) -1 */ NULL,
- - NULL,
- - NULL
- - };
- -
- X downEvent = event = *eventP;
- X *upEvent = *downEvent;
- X upEvent->event.eventType = ((event->event.eventType == ButtonPress) ?
- --- 1208,1213 ----
- ***************
- *** 1214,1219 ****
- --- 1218,1226 ----
- X upEvent->event.modifiers
- X |= buttonModifierMasks[event->event.eventCode];
- X
- + if (event->event.lateModifiers)
- + event->event.lateModifiers->ref_count += reps * 2 - 1;
- +
- X for (i=0; i<reps; i++) {
- X
- X if (i > 0) {
- ***************
- *** 1251,1263 ****
- X EventPtr upEvent = &upEventRec;
- X register int i;
- X
- - static EventSeqRec timerEventRec = {
- - {0, 0,NULL, _XtEventTimerEventType, 0L, 0L,NULL},
- - /* (StatePtr) -1 */ NULL,
- - NULL,
- - NULL
- - };
- -
- X /* the event currently sitting in *eventP is an "up" event */
- X /* we want to make it a "down" event followed by an "up" event, */
- X /* so that sequence matching on the "state" side works correctly. */
- --- 1258,1263 ----
- ***************
- *** 1272,1277 ****
- --- 1272,1280 ----
- X downEvent->event.modifiers
- X &= ~buttonModifierMasks[event->event.eventCode];
- X
- + if (event->event.lateModifiers)
- + event->event.lateModifiers->ref_count += reps * 2 - 1;
- +
- X /* up */
- X event->next = XtNew(EventSeqRec);
- X event = event->next;
- ***************
- *** 1311,1323 ****
- X EventPtr upEvent = &upEventRec;
- X register int i;
- X
- - static EventSeqRec timerEventRec = {
- - {0, 0,NULL, _XtEventTimerEventType, 0L, 0L,NULL},
- - /* (StatePtr) -1 */ NULL,
- - NULL,
- - NULL
- - };
- -
- X /* the event currently sitting in *eventP is an "up" event */
- X /* we want to make it a "down" event followed by an "up" event, */
- X /* so that sequence matching on the "state" side works correctly. */
- --- 1314,1319 ----
- ***************
- *** 1332,1337 ****
- --- 1328,1336 ----
- X downEvent->event.modifiers
- X &= ~buttonModifierMasks[event->event.eventCode];
- X
- + if (event->event.lateModifiers)
- + event->event.lateModifiers->ref_count += reps * 2;
- +
- X for (i=0; i<reps; i++) {
- X
- X /* up */
- ***************
- *** 1366,1371 ****
- --- 1365,1373 ----
- X
- X tempEvent = event = *eventP;
- X
- + if (event->event.lateModifiers)
- + event->event.lateModifiers->ref_count += reps - 1;
- +
- X for (i=1; i<reps; i++) {
- X event->next = XtNew(EventSeqRec);
- X event = event->next;
- ***************
- *** 1386,1391 ****
- --- 1388,1396 ----
- X
- X tempEvent = event = *eventP;
- X
- + if (event->event.lateModifiers)
- + event->event.lateModifiers->ref_count += reps - 1;
- +
- X for (i=1; i<reps; i++) {
- X event->next = XtNew(EventSeqRec);
- X event = event->next;
- ***************
- *** 1423,1445 ****
- X }
- X }
- X
- ! static String ParseRepeat(str, eventP, actionsP)
- X register String str;
- ! EventPtr *eventP;
- ! ActionPtr **actionsP;
- X {
- - int reps;
- - Boolean plus = FALSE;
- - String right_paren;
- X
- X /*** Parse the repetitions, for double click etc... ***/
- ! if (*str != '(') return str;
- X str++;
- ! right_paren = str;
- ! ScanFor(right_paren, ')');
- ! if (isascii(*str) && isdigit(*str)) {
- X String start = str;
- ! char repStr[100];
- X int len;
- X
- X ScanNumeric(str);
- --- 1428,1446 ----
- X }
- X }
- X
- ! static String ParseRepeat(str, reps, plus, error)
- X register String str;
- ! int *reps;
- ! Boolean *plus, *error;
- X {
- X
- X /*** Parse the repetitions, for double click etc... ***/
- ! if (*str != '(' || !(isdigit(str[1]) || str[1] == '+' || str[1] == ')'))
- ! return str;
- X str++;
- ! if (isdigit(*str)) {
- X String start = str;
- ! char repStr[7];
- X int len;
- X
- X ScanNumeric(str);
- ***************
- *** 1447,1464 ****
- X if (len < sizeof repStr) {
- X bcopy(start, repStr, len);
- X repStr[len] = '\0';
- ! reps = StrToNum(repStr);
- X } else {
- ! Syntax ("Repeat count too large; ignored.", "");
- ! return right_paren;
- X }
- ! } else {
- X Syntax("Missing repeat count.","");
- ! return right_paren;
- X }
- X
- X if (*str == '+') {
- ! plus = TRUE;
- X str++;
- X }
- X if (*str == ')')
- --- 1448,1468 ----
- X if (len < sizeof repStr) {
- X bcopy(start, repStr, len);
- X repStr[len] = '\0';
- ! *reps = StrToNum(repStr);
- X } else {
- ! Syntax("Repeat count too large.", "");
- ! *error = True;
- ! return str;
- X }
- ! }
- ! if (*reps == 0) {
- X Syntax("Missing repeat count.","");
- ! *error = True;
- ! return str;
- X }
- X
- X if (*str == '+') {
- ! *plus = TRUE;
- X str++;
- X }
- X if (*str == ')')
- ***************
- *** 1465,1475 ****
- X str++;
- X else {
- X Syntax("Missing ')'.","");
- ! return right_paren;
- X }
- X
- - if (reps > 1 || plus) RepeatEvent(eventP, reps, plus, actionsP);
- -
- X return str;
- X }
- X
- --- 1469,1477 ----
- X str++;
- X else {
- X Syntax("Missing ')'.","");
- ! *error = True;
- X }
- X
- X return str;
- X }
- X
- ***************
- *** 1525,1530 ****
- --- 1527,1535 ----
- X }
- X else str++;
- X } else {
- + int reps = 0;
- + Boolean plus = False;
- +
- X event = XtNew(EventRec);
- X event->event = nullEvent;
- X event->state = /* (StatePtr) -1 */ NULL;
- ***************
- *** 1531,1541 ****
- X event->next = NULL;
- X event->actions = NULL;
- X
- ! str = ParseEvent(str, event,error);
- X if (*error) return str;
- X *nextEvent = event;
- X *actionsP = &event->actions;
- ! str = ParseRepeat(str, &event, actionsP);
- X nextEvent = &event->next;
- X }
- X ScanWhitespace(str);
- --- 1536,1547 ----
- X event->next = NULL;
- X event->actions = NULL;
- X
- ! str = ParseEvent(str, event, &reps, &plus, error);
- X if (*error) return str;
- X *nextEvent = event;
- X *actionsP = &event->actions;
- ! if (reps > 1 || plus)
- ! RepeatEvent(&event, reps, plus, actionsP);
- X nextEvent = &event->next;
- X }
- X ScanWhitespace(str);
- *** /tmp/,RCSt1000130 Tue Mar 17 11:48:45 1992
- --- mit/lib/Xt/TMstate.c Thu Feb 27 17:06:01 1992
- ***************
- *** 1,4 ****
- ! /* $XConsortium: TMstate.c,v 1.159 91/12/03 16:33:34 converse Exp $ */
- X /*LINTLIBRARY*/
- X
- X /***********************************************************
- --- 1,4 ----
- ! /* $XConsortium: TMstate.c,v 1.161 92/02/27 17:04:04 converse Exp $ */
- X /*LINTLIBRARY*/
- X
- X /***********************************************************
- ***************
- *** 299,305 ****
- X * late modifiers. If there isn't a match we use the
- X * parser's copy
- X */
- ! if (event->lateModifiers) {
- X XtFree((char *)event->lateModifiers);
- X event->lateModifiers = NULL;
- X }
- --- 299,306 ----
- X * late modifiers. If there isn't a match we use the
- X * parser's copy
- X */
- ! if (event->lateModifiers &&
- ! --event->lateModifiers->ref_count == 0) {
- X XtFree((char *)event->lateModifiers);
- X event->lateModifiers = NULL;
- X }
- ***************
- *** 396,409 ****
- X TMModifierMatch modMatch;
- X TMEventPtr eventSeq;
- X {
- ! if (typeMatch->eventCodeMask) { /* first time? */
- ! typeMatch->eventCode = XInternAtom( eventSeq->xev->xany.display,
- ! XrmQuarkToString(typeMatch->eventCode),
- ! False
- ! );
- ! typeMatch->eventCodeMask = 0L;
- ! }
- ! return (typeMatch->eventCode == eventSeq->event.eventCode);
- X }
- X
- X #define IsOn(vec,idx) ((vec)[(idx)>>3] & (1 << ((idx) & 7)))
- --- 397,408 ----
- X TMModifierMatch modMatch;
- X TMEventPtr eventSeq;
- X {
- ! Atom atom;
- !
- ! atom = XInternAtom(eventSeq->xev->xany.display,
- ! XrmQuarkToString(typeMatch->eventCode),
- ! False);
- ! return (atom == eventSeq->event.eventCode);
- X }
- X
- X #define IsOn(vec,idx) ((vec)[(idx)>>3] & (1 << ((idx) & 7)))
- *** /tmp/,RCSt1000448 Tue Mar 17 12:03:39 1992
- --- mit/lib/Xaw/Panner.c Tue Mar 3 13:54:13 1992
- ***************
- *** 1,5 ****
- X /*
- ! * $XConsortium: Panner.c,v 1.43 91/08/26 10:53:17 gildea Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- --- 1,5 ----
- X /*
- ! * $XConsortium: Panner.c,v 1.45 92/03/03 13:52:26 converse Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- ***************
- *** 483,490 ****
- X *****************************************************************************/
- X
- X
- ! static void Initialize (greq, gnew)
- X Widget greq, gnew;
- X {
- X PannerWidget req = (PannerWidget) greq, new = (PannerWidget) gnew;
- X Dimension defwidth, defheight;
- --- 483,492 ----
- X *****************************************************************************/
- X
- X
- ! static void Initialize (greq, gnew, args, num_args)
- X Widget greq, gnew;
- + ArgList args;
- + Cardinal *num_args;
- X {
- X PannerWidget req = (PannerWidget) greq, new = (PannerWidget) gnew;
- X Dimension defwidth, defheight;
- ***************
- *** 531,537 ****
- X gotpm = TRUE;
- X }
- X }
- ! (*gw->core.widget_class->core_class.superclass->core_class.realize)
- X (gw, valuemaskp, attr);
- X
- X if (gotpm) XFreePixmap (XtDisplay(gw), pm);
- --- 533,539 ----
- X gotpm = TRUE;
- X }
- X }
- ! (*pannerWidgetClass->core_class.superclass->core_class.realize)
- X (gw, valuemaskp, attr);
- X
- X if (gotpm) XFreePixmap (XtDisplay(gw), pm);
- ***************
- *** 599,606 ****
- X
- X
- X /* ARGSUSED */
- ! static Boolean SetValues (gcur, greq, gnew)
- X Widget gcur, greq, gnew;
- X {
- X PannerWidget cur = (PannerWidget) gcur;
- X PannerWidget new = (PannerWidget) gnew;
- --- 601,610 ----
- X
- X
- X /* ARGSUSED */
- ! static Boolean SetValues (gcur, greq, gnew, args, num_args)
- X Widget gcur, greq, gnew;
- + ArgList args;
- + Cardinal *num_args;
- X {
- X PannerWidget cur = (PannerWidget) gcur;
- X PannerWidget new = (PannerWidget) gnew;
- *** /tmp/,RCSt1000745 Tue Mar 17 15:21:29 1992
- --- mit/clients/xterm/Imakefile Wed Mar 11 17:36:06 1992
- ***************
- *** 1,4 ****
- ! XCOMM $XConsortium: Imakefile,v 1.55 91/09/22 11:40:47 rws Exp $
- X XCOMM
- X XCOMM Attention xterm porters
- X XCOMM
- --- 1,4 ----
- ! XCOMM $XConsortium: Imakefile,v 1.56 92/03/11 17:35:22 gildea Exp $
- X XCOMM
- X XCOMM Attention xterm porters
- X XCOMM
- ***************
- *** 20,26 ****
- X PTYLIB = -lpucc
- X #endif
- X
- ! MAIN_DEFINES = -DUTMP $(TTYGROUPDEF) $(PUCCPTYDDEF)
- X MISC_DEFINES = /* -DALLOWLOGFILEEXEC */
- X
- X SRCS1 = button.c charproc.c cursor.c data.c input.c \
- --- 20,31 ----
- X PTYLIB = -lpucc
- X #endif
- X
- ! OSMAJORVERSION = OSMajorVersion
- ! OSMINORVERSION = OSMinorVersion
- !
- ! MAIN_DEFINES = -DUTMP $(TTYGROUPDEF) $(PUCCPTYDDEF) \
- ! -DOSMAJORVERSION=$(OSMAJORVERSION) \
- ! -DOSMINORVERSION=$(OSMINORVERSION)
- X MISC_DEFINES = /* -DALLOWLOGFILEEXEC */
- X
- X SRCS1 = button.c charproc.c cursor.c data.c input.c \
- *** /tmp/,RCSt1000549 Tue Mar 17 12:09:36 1992
- --- mit/clients/xterm/main.c Wed Mar 11 17:37:01 1992
- ***************
- *** 1,5 ****
- X #ifndef lint
- ! static char *rid="$XConsortium: main.c,v 1.199 91/12/23 17:02:24 gildea Exp $";
- X #endif /* lint */
- X
- X /*
- --- 1,5 ----
- X #ifndef lint
- ! static char *rid="$XConsortium: main.c,v 1.200 92/03/11 17:36:12 gildea Exp $";
- X #endif /* lint */
- X
- X /*
- ***************
- *** 1208,1214 ****
- X strcpy(ttydev, ttyname(*pty));
- X return 0;
- X #endif
- ! #ifdef sgi
- X {
- X char *tty_name;
- X
- --- 1208,1214 ----
- X strcpy(ttydev, ttyname(*pty));
- X return 0;
- X #endif
- ! #if defined(sgi) && OSMAJORVERSION >= 4
- X {
- X char *tty_name;
- X
- ***************
- *** 1237,1243 ****
- X #ifdef USE_GET_PSEUDOTTY
- X return ((*pty = getpseudotty (&ttydev, &ptydev)) >= 0 ? 0 : 1);
- X #else
- ! #if (defined(umips) && defined (SYSTYPE_SYSV))
- X struct stat fstat_buf;
- X
- X *pty = open ("/dev/ptc", O_RDWR);
- --- 1237,1243 ----
- X #ifdef USE_GET_PSEUDOTTY
- X return ((*pty = getpseudotty (&ttydev, &ptydev)) >= 0 ? 0 : 1);
- X #else
- ! #if (defined(sgi) && OSMAJORVERSION < 4) || (defined(umips) && defined (SYSTYPE_SYSV))
- X struct stat fstat_buf;
- X
- X *pty = open ("/dev/ptc", O_RDWR);
- *** /tmp/,RCSt1000569 Tue Mar 17 12:10:45 1992
- --- mit/clients/xterm/misc.c Fri Mar 13 17:04:37 1992
- ***************
- *** 1,5 ****
- X /*
- ! * $XConsortium: misc.c,v 1.90 91/07/25 17:59:05 rws Exp $
- X */
- X
- X /*
- --- 1,5 ----
- X /*
- ! * $XConsortium: misc.c,v 1.92 92/03/13 17:02:08 gildea Exp $
- X */
- X
- X /*
- ***************
- *** 254,262 ****
- X (event->detail == NotifyPointer) ? INWINDOW :
- X FOCUS);
- X if (screen->grabbedKbd && (event->mode == NotifyUngrab)) {
- - screen->grabbedKbd = FALSE;
- - ReverseVideo(term);
- X XBell(screen->display, 100);
- X }
- X }
- X }
- --- 254,263 ----
- X (event->detail == NotifyPointer) ? INWINDOW :
- X FOCUS);
- X if (screen->grabbedKbd && (event->mode == NotifyUngrab)) {
- X XBell(screen->display, 100);
- + ReverseVideo(term);
- + screen->grabbedKbd = FALSE;
- + update_securekbd();
- X }
- X }
- X }
- ***************
- *** 570,576 ****
- X
- X cp = screen->TekEmu ? Tbptr : bptr;
- X if((i = cp - screen->logstart) > 0)
- ! write(screen->logfd, screen->logstart, i);
- X screen->logstart = screen->TekEmu ? Tbuffer : buffer;
- X }
- X
- --- 571,577 ----
- X
- X cp = screen->TekEmu ? Tbptr : bptr;
- X if((i = cp - screen->logstart) > 0)
- ! write(screen->logfd, (char *)screen->logstart, i);
- X screen->logstart = screen->TekEmu ? Tbuffer : buffer;
- X }
- X
- *** /tmp/,RCSt1000589 Tue Mar 17 12:12:00 1992
- --- mit/clients/xterm/charproc.c Fri Mar 13 18:01:33 1992
- ***************
- *** 1,5 ****
- X /*
- ! * $XConsortium: charproc.c,v 1.173 91/07/22 11:32:49 gildea Exp $
- X */
- X
- X /*
- --- 1,5 ----
- X /*
- ! * $XConsortium: charproc.c,v 1.176 92/03/13 18:00:30 gildea Exp $
- X */
- X
- X /*
- ***************
- *** 1253,1259 ****
- X if (select_mask & pty_mask && eventMode == NORMAL) {
- X if (screen->logging)
- X FlushLog(screen);
- ! bcnt = read(screen->respond, bptr = buffer, BUF_SIZE);
- X if (bcnt < 0) {
- X if (errno == EIO)
- X Cleanup (0);
- --- 1253,1259 ----
- X if (select_mask & pty_mask && eventMode == NORMAL) {
- X if (screen->logging)
- X FlushLog(screen);
- ! bcnt = read(screen->respond, (char *)(bptr = buffer), BUF_SIZE);
- X if (bcnt < 0) {
- X if (errno == EIO)
- X Cleanup (0);
- ***************
- *** 1508,1513 ****
- --- 1508,1514 ----
- X switch (param[i]) {
- X case 1: /* DECCKM */
- X (*func)(&termw->keyboard.flags, CURSOR_APL);
- + update_appcursor();
- X break;
- X case 2: /* ANSI/VT52 mode */
- X if (func == bitset) {
- ***************
- *** 1587,1593 ****
- X screen->send_mouse_pos = 0;
- X break;
- X case 38: /* DECTEK */
- ! if(func == bitset & !(screen->inhibit & I_TEK)) {
- X if(screen->logging) {
- X FlushLog(screen);
- X screen->logstart = Tbuffer;
- --- 1588,1594 ----
- X screen->send_mouse_pos = 0;
- X break;
- X case 38: /* DECTEK */
- ! if(func == bitset && !(screen->inhibit & I_TEK)) {
- X if(screen->logging) {
- X FlushLog(screen);
- X screen->logstart = Tbuffer;
- ***************
- *** 1812,1818 ****
- X case 44: /* margin bell */
- X if(!(screen->marginbell = screen->save_modes[12]))
- X screen->bellarmed = -1;
- ! update_visualbell();
- X break;
- X case 45: /* reverse wraparound */
- X termw->flags &= ~REVERSEWRAP;
- --- 1813,1819 ----
- X case 44: /* margin bell */
- X if(!(screen->marginbell = screen->save_modes[12]))
- X screen->bellarmed = -1;
- ! update_marginbell();
- X break;
- X case 45: /* reverse wraparound */
- X termw->flags &= ~REVERSEWRAP;
- ***************
- *** 2149,2158 ****
- X }
- X
- X
- ! static void VTInitialize (request, new)
- ! XtermWidget request, new;
- X {
- X int i;
- X /* Zero out the entire "screen" component of "new" widget,
- X then do field-by-field assigment of "screen" fields
- X that are named in the resource list. */
- --- 2150,2165 ----
- X }
- X
- X
- ! /* ARGSUSED */
- ! static void VTInitialize (wrequest, wnew, args, num_args)
- ! Widget wrequest, wnew;
- ! ArgList args;
- ! Cardinal *num_args;
- X {
- + XtermWidget request = (XtermWidget) wrequest;
- + XtermWidget new = (XtermWidget) wnew;
- X int i;
- +
- X /* Zero out the entire "screen" component of "new" widget,
- X then do field-by-field assigment of "screen" fields
- X that are named in the resource list. */
- ***************
- *** 2402,2408 ****
- X screen->bot_marg = screen->max_row = Height(screen) /
- X screen->fullVwin.f_height - 1;
- X
- ! screen->sc.row = screen->sc.col = screen->sc.flags = NULL;
- X
- X /* Mark screen buffer as unallocated. We wait until the run loop so
- X that the child process does not fork and exec with all the dynamic
- --- 2409,2415 ----
- X screen->bot_marg = screen->max_row = Height(screen) /
- X screen->fullVwin.f_height - 1;
- X
- ! screen->sc.row = screen->sc.col = screen->sc.flags = 0;
- X
- X /* Mark screen buffer as unallocated. We wait until the run loop so
- X that the child process does not fork and exec with all the dynamic
- ***************
- *** 2411,2417 ****
- X if (!tekWidget) /* if not called after fork */
- X screen->buf = screen->allbuf = NULL;
- X
- ! screen->do_wrap = NULL;
- X screen->scrolls = screen->incopy = 0;
- X set_vt_box (screen);
- X
- --- 2418,2424 ----
- X if (!tekWidget) /* if not called after fork */
- X screen->buf = screen->allbuf = NULL;
- X
- ! screen->do_wrap = 0;
- X screen->scrolls = screen->incopy = 0;
- X set_vt_box (screen);
- X
- ***************
- *** 2641,2647 ****
- X term->flags &= ~ORIGIN;
- X if(full) {
- X TabReset (term->tabs);
- ! term->keyboard.flags = NULL;
- X update_appcursor();
- X update_appkeypad();
- X screen->gsets[0] = 'B';
- --- 2648,2654 ----
- X term->flags &= ~ORIGIN;
- X if(full) {
- X TabReset (term->tabs);
- ! term->keyboard.flags = 0;
- X update_appcursor();
- X update_appkeypad();
- X screen->gsets[0] = 'B';
- *** /tmp/,RCSt1029848 Tue Mar 17 11:36:12 1992
- --- mit/clients/editres/widgets.c Tue Feb 11 11:49:17 1992
- ***************
- *** 1,5 ****
- X /*
- ! * $XConsortium: widgets.c,v 1.19 91/12/06 17:20:00 dave Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- --- 1,5 ----
- X /*
- ! * $XConsortium: widgets.c,v 1.20 92/02/11 11:44:24 dave Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- ***************
- *** 835,840 ****
- --- 835,842 ----
- X WNode * node = (WNode *) ptr;
- X NameInfo *old_name, *name = node->resources->res_box->name_info;
- X
- + global_resource_box_up = FALSE;
- +
- X XtFree((XtPointer) node->resources->res_box);
- X node->resources->res_box = NULL;
- X
- *** /tmp/,RCSt1029866 Tue Mar 17 11:37:36 1992
- --- mit/clients/editres/handler.c Tue Feb 11 11:49:22 1992
- ***************
- *** 1,5 ****
- X /*
- ! * $XConsortium: handler.c,v 1.25 91/10/09 17:36:13 dave Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- --- 1,5 ----
- X /*
- ! * $XConsortium: handler.c,v 1.26 92/02/11 11:45:31 dave Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- ***************
- *** 561,569 ****
- X XtPointer shell_ptr, junk;
- X {
- X Widget shell = (Widget) shell_ptr;
- -
- - if (streq(XtName(shell), RESOURCE_BOX))
- - global_resource_box_up = FALSE;
- X
- X XtPopdown(shell);
- X XtDestroyWidget(shell);
- --- 561,566 ----
- *** /tmp/,RCSt1029944 Tue Mar 17 11:42:43 1992
- --- mit/clients/xauth/process.c Tue Feb 18 18:05:08 1992
- ***************
- *** 1,5 ****
- X /*
- ! * $XConsortium: process.c,v 1.41 92/01/22 23:39:12 gildea Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- --- 1,5 ----
- X /*
- ! * $XConsortium: process.c,v 1.42 92/02/18 18:05:00 gildea Exp $
- X *
- X * Copyright 1989 Massachusetts Institute of Technology
- X *
- ***************
- *** 330,348 ****
- X {
- X char *s;
- X register char *cp;
- ! char buf[2];
- X
- X cp = s = malloc (n);
- X if (!cp) return 0;
- X
- X while (n > 0) {
- ! if ((buf[0] = getinput (fp)) == EOF || buf[0] == '\n' ||
- ! (buf[1] = getinput (fp)) == EOF || buf[1] == '\n') {
- X free (s);
- X return 0;
- X }
- ! *cp = (char) ((hexvalues[(unsigned int)buf[0]] * 16) +
- ! hexvalues[(unsigned int)buf[1]]);
- X cp++;
- X n--;
- X }
- --- 330,347 ----
- X {
- X char *s;
- X register char *cp;
- ! int c1, c2;
- X
- X cp = s = malloc (n);
- X if (!cp) return 0;
- X
- X while (n > 0) {
- ! if ((c1 = getinput (fp)) == EOF || c1 == '\n' ||
- ! (c2 = getinput (fp)) == EOF || c2 == '\n') {
- X free (s);
- X return 0;
- X }
- ! *cp = (char) ((hexvalues[c1] * 16) + hexvalues[c2]);
- X cp++;
- X n--;
- X }
- SHAR_EOF
- echo 'File fix-10 is complete' &&
- chmod 0644 fix-10 ||
- echo 'restore of fix-10 failed'
- Wc_c="`wc -c < 'fix-10'`"
- test 85909 -eq "$Wc_c" ||
- echo 'fix-10: original size 85909, current size' "$Wc_c"
- rm -f _shar_wnt_.tmp
- fi
- rm -f _shar_seq_.tmp
- echo You have unpacked the last part
- exit 0
- --
- ---
- Senior Systems Scientist mail: dcmartin@msi.com
- Molecular Simulations, Inc. uucp: uunet!dcmartin
- 796 North Pastoria Avenue at&t: 408/522-9236
-