Lines Matching refs:pSel
74 Selection *pSel; in dixLookupSelection() local
79 for (pSel = CurrentSelections; pSel; pSel = pSel->next) in dixLookupSelection()
80 if (pSel->selection == selectionName) in dixLookupSelection()
83 if (pSel) in dixLookupSelection()
84 rc = XaceHookSelectionAccess(client, &pSel, access_mode); in dixLookupSelection()
85 *result = pSel; in dixLookupSelection()
92 Selection *pSel, *pNextSel; in InitSelections() local
94 pSel = CurrentSelections; in InitSelections()
95 while (pSel) { in InitSelections()
96 pNextSel = pSel->next; in InitSelections()
97 dixFreeObjectWithPrivates(pSel, PRIVATE_SELECTION); in InitSelections()
98 pSel = pNextSel; in InitSelections()
105 CallSelectionCallback(Selection * pSel, ClientPtr client, in CallSelectionCallback() argument
108 SelectionInfoRec info = { pSel, client, kind }; in CallSelectionCallback()
115 Selection *pSel; in DeleteWindowFromAnySelections() local
117 for (pSel = CurrentSelections; pSel; pSel = pSel->next) in DeleteWindowFromAnySelections()
118 if (pSel->pWin == pWin) { in DeleteWindowFromAnySelections()
119 CallSelectionCallback(pSel, NULL, SelectionWindowDestroy); in DeleteWindowFromAnySelections()
121 pSel->pWin = (WindowPtr) NULL; in DeleteWindowFromAnySelections()
122 pSel->window = None; in DeleteWindowFromAnySelections()
123 pSel->client = NullClient; in DeleteWindowFromAnySelections()
130 Selection *pSel; in DeleteClientFromAnySelections() local
132 for (pSel = CurrentSelections; pSel; pSel = pSel->next) in DeleteClientFromAnySelections()
133 if (pSel->client == client) { in DeleteClientFromAnySelections()
134 CallSelectionCallback(pSel, NULL, SelectionClientClose); in DeleteClientFromAnySelections()
136 pSel->pWin = (WindowPtr) NULL; in DeleteClientFromAnySelections()
137 pSel->window = None; in DeleteClientFromAnySelections()
138 pSel->client = NullClient; in DeleteClientFromAnySelections()
147 Selection *pSel; in ProcSetSelectionOwner() local
174 rc = dixLookupSelection(&pSel, stuff->selection, client, DixSetAttrAccess); in ProcSetSelectionOwner()
181 if (CompareTimeStamps(time, pSel->lastTimeChanged) == EARLIER) in ProcSetSelectionOwner()
183 if (pSel->client && (!pWin || (pSel->client != client))) { in ProcSetSelectionOwner()
186 .u.selectionClear.window = pSel->window, in ProcSetSelectionOwner()
187 .u.selectionClear.atom = pSel->selection in ProcSetSelectionOwner()
190 WriteEventsToClient(pSel->client, 1, &event); in ProcSetSelectionOwner()
197 pSel = dixAllocateObjectWithPrivates(Selection, PRIVATE_SELECTION); in ProcSetSelectionOwner()
198 if (!pSel) in ProcSetSelectionOwner()
201 pSel->selection = stuff->selection; in ProcSetSelectionOwner()
204 rc = XaceHookSelectionAccess(client, &pSel, in ProcSetSelectionOwner()
207 free(pSel); in ProcSetSelectionOwner()
211 pSel->next = CurrentSelections; in ProcSetSelectionOwner()
212 CurrentSelections = pSel; in ProcSetSelectionOwner()
217 pSel->lastTimeChanged = time; in ProcSetSelectionOwner()
218 pSel->window = stuff->window; in ProcSetSelectionOwner()
219 pSel->pWin = pWin; in ProcSetSelectionOwner()
220 pSel->client = (pWin ? client : NullClient); in ProcSetSelectionOwner()
222 CallSelectionCallback(pSel, client, SelectionSetOwner); in ProcSetSelectionOwner()
230 Selection *pSel; in ProcGetSelectionOwner() local
247 rc = dixLookupSelection(&pSel, stuff->id, client, DixGetAttrAccess); in ProcGetSelectionOwner()
249 reply.owner = pSel->window; in ProcGetSelectionOwner()
265 Selection *pSel; in ProcConvertSelection() local
285 rc = dixLookupSelection(&pSel, stuff->selection, client, DixReadAccess); in ProcConvertSelection()
290 else if (rc == Success && pSel->window != None) { in ProcConvertSelection()
292 event.u.selectionRequest.owner = pSel->window; in ProcConvertSelection()
298 if (pSel->client && pSel->client != serverClient && in ProcConvertSelection()
299 !pSel->client->clientGone) { in ProcConvertSelection()
300 WriteEventsToClient(pSel->client, 1, &event); in ProcConvertSelection()