Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!cs.utexas.edu!uunet!resq!Uucp From: Uucp@resq.fidonet.org (Uucp) Newsgroups: comp.windows.x.motif Subject: Re: XmStringGetLtoR and Loss of Keyboard Focus Message-ID: <32.27EF5231@resq.fidonet.org> Date: 25 Mar 91 12:56:50 GMT Organization: RES-Q, Paterson NJ (201) 881-7421 Lines: 24 From uunet!osf.org!motif-talk-request From: uunet!alfalfa.com!nazgul (Kee Hinckley) To: nazgul@alfalfa.com (Kee Hinckley) Date: Fri, 22 Mar 91 16:41:16 -0500 Cc: larry@sunrise.com (Larry Rogers), motif-talk@osf.org A minor correction to that code (not that it matters out of context, but...) > if (shell && XtParent(shell) && XtIsRealized(XtParent(shell))) { > XtUngrabKeyboard(XtParent(shell), CurrentTime); > if (shell == widget) { > Cardinal numKids, i; > Widget *kids; > > arglist.add(XmNchildren, &kids, XmNnumChildren, &numKids, NULL); > XtGetValues(shell, arglist.args, arglist.clear()); > for (i = 0; i < numKids; ++i) if (XtIsManaged(kids[i])) break; > if (i < numKids) XtSetKeyboardFocus(shell, kids[i]); > } } else XtSetKeyboardFocus(shell, widget); > } -- Uucp - via FidoNet node 1:269/133 UUCP: uunet!resq!Uucp