Lines Matching refs:key
69 DevPrivateKey key;
89 * This initializes the specified key and optionally requests pre-allocated
91 * may set and get a single pointer value using this private key. Otherwise,
95 * You may call dixRegisterPrivateKey more than once on the same key, but the
102 dixRegisterPrivateKey(DevPrivateKey key, DevPrivateType type, unsigned size);
105 * Check whether a private key has been registered
108 dixPrivateKeyRegistered(DevPrivateKey key)
110 return key->initialized;
120 dixGetPrivateAddr(PrivatePtr *privates, const DevPrivateKey key)
122 assert(key->initialized);
123 return (char *) (*privates) + key->offset;
134 dixGetPrivate(PrivatePtr *privates, const DevPrivateKey key)
136 assert(key->size == 0);
137 return *(void **) dixGetPrivateAddr(privates, key);
141 * Associate 'val' with 'key' in 'privates' so that later calls to
142 * dixLookupPrivate(privates, key) will return 'val'.
145 dixSetPrivate(PrivatePtr *privates, const DevPrivateKey key, void *val)
147 assert(key->size == 0);
148 *(void **) dixGetPrivateAddr(privates, key) = val;
162 dixLookupPrivate(PrivatePtr *privates, const DevPrivateKey key)
164 if (key->size)
165 return dixGetPrivateAddr(privates, key);
167 return dixGetPrivate(privates, key);
177 dixLookupPrivateAddr(PrivatePtr *privates, const DevPrivateKey key)
179 assert(key->size == 0);
180 return (void **) dixGetPrivateAddr(privates, key);
185 dixRegisterScreenPrivateKey(DevScreenPrivateKey key, ScreenPtr pScreen,
189 _dixGetScreenPrivateKey(const DevScreenPrivateKey key, ScreenPtr pScreen);
192 dixGetScreenPrivateAddr(PrivatePtr *privates, const DevScreenPrivateKey key,
195 return dixGetPrivateAddr(privates, _dixGetScreenPrivateKey(key, pScreen));
199 dixGetScreenPrivate(PrivatePtr *privates, const DevScreenPrivateKey key,
202 return dixGetPrivate(privates, _dixGetScreenPrivateKey(key, pScreen));
206 dixSetScreenPrivate(PrivatePtr *privates, const DevScreenPrivateKey key,
209 dixSetPrivate(privates, _dixGetScreenPrivateKey(key, pScreen), val);
213 dixLookupScreenPrivate(PrivatePtr *privates, const DevScreenPrivateKey key,
216 return dixLookupPrivate(privates, _dixGetScreenPrivateKey(key, pScreen));
220 dixLookupScreenPrivateAddr(PrivatePtr *privates, const DevScreenPrivateKey key,
224 _dixGetScreenPrivateKey(key, pScreen));
232 * windows, pixmaps, gcs, pictures and colormaps. This key is
233 * used just like any other key using dixGetPrivate and friends.
244 dixRegisterScreenSpecificPrivateKey(ScreenPtr pScreen, DevPrivateKey key,