Lines Matching full:focus

1333             else if (replayDev->focus &&  in ComputeFreezes()
1639 else if (keybd->focus) in ActivateKeyboardGrab()
1640 oldWin = keybd->focus->win; in ActivateKeyboardGrab()
1644 oldWin = keybd->focus->win; in ActivateKeyboardGrab()
1687 if (keybd->focus) in DeactivateKeyboardGrab()
1688 focusWin = keybd->focus->win; in DeactivateKeyboardGrab()
1695 focusWin = inputInfo.keyboard->focus->win; in DeactivateKeyboardGrab()
2700 * For events from a non-grabbed, non-focus device, DeliverDeviceEvents is
3978 * If the event is a keyboard event, the ancestors of the focus window are
3980 * activated. If the focus window itself is reached and it's descendants
3982 * are then traced down starting at the focus window, otherwise no grabs are
4005 FocusClassPtr focus = in CheckDeviceGrabs() local
4006 IsPointerEvent((InternalEvent *) event) ? NULL : device->focus; in CheckDeviceGrabs()
4028 if (focus) { in CheckDeviceGrabs()
4029 for (; i < focus->traceGood; i++) { in CheckDeviceGrabs()
4030 pWin = focus->trace[i]; in CheckDeviceGrabs()
4038 if ((focus->win == NoneWin) || in CheckDeviceGrabs()
4061 * focus.
4063 * The event is delivered to the keyboard's focus window, the root window or
4064 * to the window owning the input focus.
4074 WindowPtr focus = keybd->focus->win; in DeliverFocusedEvent() local
4080 if (focus == FollowKeyboardWin) in DeliverFocusedEvent()
4081 focus = inputInfo.keyboard->focus->win; in DeliverFocusedEvent()
4082 if (!focus) in DeliverFocusedEvent()
4084 if (focus == PointerRootWin) { in DeliverFocusedEvent()
4088 if ((focus == window) || IsParent(focus, window)) { in DeliverFocusedEvent()
4089 if (DeliverDeviceEvents(window, event, NullGrab, focus, keybd)) in DeliverFocusedEvent()
4093 /* just deliver it to the focus window */ in DeliverFocusedEvent()
4101 FixUpEventFromWindow(ptr->spriteInfo->sprite, xi2, focus, None, FALSE); in DeliverFocusedEvent()
4102 deliveries = DeliverEventsToWindow(keybd, focus, xi2, 1, in DeliverFocusedEvent()
4114 XaceHook(XACE_SEND_ACCESS, NULL, keybd, focus, xE, count) == Success) { in DeliverFocusedEvent()
4115 FixUpEventFromWindow(ptr->spriteInfo->sprite, xE, focus, None, FALSE); in DeliverFocusedEvent()
4116 deliveries = DeliverEventsToWindow(keybd, focus, xE, count, in DeliverFocusedEvent()
4130 if (XaceHook(XACE_SEND_ACCESS, NULL, keybd, focus, core, count) == in DeliverFocusedEvent()
4132 FixUpEventFromWindow(keybd->spriteInfo->sprite, core, focus, in DeliverFocusedEvent()
4135 DeliverEventsToWindow(keybd, focus, core, count, in DeliverFocusedEvent()
4246 WindowPtr focus; in DeliverGrabbedEvent() local
4248 /* Hack: Some pointer device have a focus class. So we need to check in DeliverGrabbedEvent()
4250 * the focus window. For pointer events, the answer is no. in DeliverGrabbedEvent()
4253 focus = PointerRootWin; in DeliverGrabbedEvent()
4254 else if (thisDev->focus) { in DeliverGrabbedEvent()
4255 focus = thisDev->focus->win; in DeliverGrabbedEvent()
4256 if (focus == FollowKeyboardWin) in DeliverGrabbedEvent()
4257 focus = inputInfo.keyboard->focus->win; in DeliverGrabbedEvent()
4260 focus = PointerRootWin; in DeliverGrabbedEvent()
4261 if (focus == PointerRootWin) in DeliverGrabbedEvent()
4264 else if (focus && (focus == pSprite->win || in DeliverGrabbedEvent()
4265 IsParent(focus, pSprite->win))) in DeliverGrabbedEvent()
4266 deliveries = DeliverDeviceEvents(pSprite->win, event, grab, focus, in DeliverGrabbedEvent()
4268 else if (focus) in DeliverGrabbedEvent()
4269 deliveries = DeliverDeviceEvents(focus, event, grab, focus, in DeliverGrabbedEvent()
4542 WindowPtr focus; in CoreEnterLeaveEvent() local
4576 focus = (keybd) ? keybd->focus->win : None; in CoreEnterLeaveEvent()
4577 if ((focus != NoneWin) && in CoreEnterLeaveEvent()
4578 ((pWin == focus) || (focus == PointerRootWin) || IsParent(focus, pWin))) in CoreEnterLeaveEvent()
4618 WindowPtr focus; in DeviceEnterLeaveEvent() local
4660 focus = (kbd) ? kbd->focus->win : None; in DeviceEnterLeaveEvent()
4661 if ((focus != NoneWin) && in DeviceEnterLeaveEvent()
4662 ((pWin == focus) || (focus == PointerRootWin) || IsParent(focus, pWin))) in DeviceEnterLeaveEvent()
4663 event->focus = TRUE; in DeviceEnterLeaveEvent()
4695 event.u.focus.mode = mode; in CoreFocusEvent()
4696 event.u.focus.window = pWin->drawable.id; in CoreFocusEvent()
4718 * Set the input focus to the given window. Subsequent keyboard events will be
4726 * @param client Client that requested input focus change.
4727 * @param dev Focus device.
4728 * @param focusID The window to obtain the focus. Can be PointerRoot or None.
4729 * @param revertTo Specifies where the focus reverts to when window becomes
4739 FocusClassPtr focus; in SetInputFocus() local
4760 focusWin = keybd->focus->win; in SetInputFocus()
4766 /* It is a match error to try to set the input focus to an in SetInputFocus()
4775 focus = dev->focus; in SetInputFocus()
4777 (CompareTimeStamps(time, focus->time) == EARLIER)) in SetInputFocus()
4780 if (focus->win == FollowKeyboardWin) { in SetInputFocus()
4781 if (!ActivateFocusInGrab(dev, keybd->focus->win, focusWin)) in SetInputFocus()
4782 DoFocusEvents(dev, keybd->focus->win, focusWin, mode); in SetInputFocus()
4785 if (!ActivateFocusInGrab(dev, focus->win, focusWin)) in SetInputFocus()
4786 DoFocusEvents(dev, focus->win, focusWin, mode); in SetInputFocus()
4788 focus->time = time; in SetInputFocus()
4789 focus->revert = revertTo; in SetInputFocus()
4791 focus->win = FollowKeyboardWin; in SetInputFocus()
4793 focus->win = focusWin; in SetInputFocus()
4795 focus->traceGood = 0; in SetInputFocus()
4802 if (depth > focus->traceSize) { in SetInputFocus()
4803 focus->traceSize = depth + 1; in SetInputFocus()
4804 focus->trace = reallocarray(focus->trace, focus->traceSize, in SetInputFocus()
4807 focus->traceGood = depth; in SetInputFocus()
4809 focus->trace[depth] = pWin; in SetInputFocus()
4817 * Sets the input focus for the virtual core keyboard.
4828 return SetInputFocus(client, kbd, stuff->focus, in ProcSetInputFocus()
4835 * Sends the current input focus for the client's keyboard back to the
4843 FocusClassPtr focus = kbd->focus; in ProcGetInputFocus() local
4857 .revertTo = focus->revert in ProcGetInputFocus()
4860 if (focus->win == NoneWin) in ProcGetInputFocus()
4861 rep.focus = None; in ProcGetInputFocus()
4862 else if (focus->win == PointerRootWin) in ProcGetInputFocus()
4863 rep.focus = PointerRoot; in ProcGetInputFocus()
4865 rep.focus = focus->win->drawable.id; in ProcGetInputFocus()
5395 WindowPtr inputFocus = (keybd) ? keybd->focus->win : NoneWin; in ProcSendEvent()
5400 /* If the input focus is PointerRootWin, send the event to where in ProcSendEvent()
5694 * Deactivate any grab that may be on the window, remove the focus.
5710 FocusClassPtr focus; in DeleteWindowFromAnyEvents() local
5716 input focus changes. */ in DeleteWindowFromAnyEvents()
5721 /* Deactivating a keyboard grab should cause focus events. */ in DeleteWindowFromAnyEvents()
5735 focus = keybd->focus; in DeleteWindowFromAnyEvents()
5737 /* If the focus window is a root window (ie. has no parent) in DeleteWindowFromAnyEvents()
5738 then don't delete the focus from it. */ in DeleteWindowFromAnyEvents()
5740 if ((pWin == focus->win) && (pWin->parent != NullWindow)) { in DeleteWindowFromAnyEvents()
5743 /* If a grab is in progress, then alter the mode of focus events. */ in DeleteWindowFromAnyEvents()
5748 switch (focus->revert) { in DeleteWindowFromAnyEvents()
5751 focus->win = NoneWin; in DeleteWindowFromAnyEvents()
5752 focus->traceGood = 0; in DeleteWindowFromAnyEvents()
5758 focus->traceGood--; in DeleteWindowFromAnyEvents()
5762 focus to revert to the nearest enclosing window which in DeleteWindowFromAnyEvents()
5772 focus->win = parent; in DeleteWindowFromAnyEvents()
5773 focus->revert = RevertToNone; in DeleteWindowFromAnyEvents()
5779 focus->win = PointerRootWin; in DeleteWindowFromAnyEvents()
5780 focus->traceGood = 0; in DeleteWindowFromAnyEvents()