Lines Matching refs:dgawin
41 static void dgai_mbsmemb_notifySiteChg (_Dga_window dgawin);
42 static void dgai_mbsmemb_notifyMbChg (_Dga_window dgawin);
43 static void dgai_mbsmemb_notifyOvlState (_Dga_window dgawin);
54 _Dga_window dgawin = (_Dga_window) dgadraw;
59 mutex_lock(dgawin->mutexp); /* lock the per-window mutex */
62 if (dgawin->shadow_chngcnt[bufIndex + 1] == *dgawin->s_chngcnt_p) {
64 mutex_unlock(dgawin->mutexp);
71 dgawin->rLockSubj = bufIndex;
74 dgawin->eLockSubjPrev = dgawin->eLockSubj;
78 dgawin->eLockSubj = dgawin->rLockSubj;
83 status = dgai_win_update(dgawin, bufIndex);
85 status = dgai_mbuf_update(dgawin, bufIndex);
90 dgawin->shadow_chngcnt[bufIndex + 1] =
91 dgawin->c_wm_chngcnt[bufIndex + 1];
96 dgawin->c_wm_chngcnt[bufIndex + 1] = *dgawin->s_chngcnt_p - 1;
98 mutex_unlock(dgawin->mutexp); /* unlock the per-window mutex */
113 dgai_mbsmemb_syncZombie (_Dga_window dgawin)
117 infop = (WXINFO *) dgawin->w_info;
120 dgawin->changeMask |= DGA_CHANGE_ZOMBIE;
133 dgai_mbsmemb_syncMbufset (_Dga_window dgawin)
141 if (dgawin->c_mbcomposseq == *dgawin->s_mbcomposseq_p) {
149 infop = (WXINFO *) dgawin->w_info;
150 pMbs = dgawin->pMbs;
155 dgawin->prevWasMbuffered = (pMbs != NULL);
160 dgawin->pMbs = NULL;
163 dgawin->c_mbcomposseq = *dgawin->s_mbcomposseq_p;
170 pMbs = dgai_mbufset_create(dgawin);
175 dgawin->changeMask |= DGA_CHANGE_ZOMBIE;
178 dgawin->pMbs = pMbs;
190 dgai_mbsmemb_syncRendBuf (_Dga_window dgawin)
195 infop = (WXINFO *) dgawin->w_info;
198 if (!dgawin->rendBufNotifyFunc) {
213 if (*pRendBuf != dgawin->eLockSubj) {
214 (*dgawin->rendBufNotifyFunc)((Dga_drawable)dgawin, dgawin->eLockSubj,
215 dgawin->rendBufNotifyClientData);
219 *pRendBuf = dgawin->eLockSubj;
232 dgai_mbsmemb_figureDerivChgs (_Dga_window dgawin)
235 dgawin->siteChgReason = DGA_SITECHG_UNKNOWN;
238 if (dgawin->changeMask & DGA_CHANGE_ZOMBIE) {
241 dgawin->changeMask |= (DGA_CHANGE_SITE | DGA_CHANGE_CLIP);
242 dgawin->siteChgReason = DGA_SITECHG_ZOMBIE;
247 if ((dgawin->eLockSubj == -1) && !dgawin->prevLocked) {
248 dgawin->changeMask |= DGA_CHANGE_SITE;
249 dgawin->siteChgReason = DGA_SITECHG_INITIAL;
250 dgawin->prevLocked = 1;
252 } else if ((dgawin->eLockSubj >= 0) &&
253 !dgawin->pMbs->prevLocked[(int)dgawin->eLockSubj]) {
254 dgawin->changeMask |= DGA_CHANGE_SITE;
255 dgawin->siteChgReason = DGA_SITECHG_INITIAL;
256 dgawin->pMbs->prevLocked[dgawin->eLockSubj] = 1;
261 if (dgawin->changeMask & DGA_CHANGE_CACHE) {
262 dgawin->changeMask |= DGA_CHANGE_SITE;
263 dgawin->siteChgReason = DGA_SITECHG_CACHE;
268 if (dgawin->changeMask & DGA_CHANGE_ALIAS) {
269 dgawin->changeMask |= DGA_CHANGE_SITE;
270 dgawin->siteChgReason = DGA_SITECHG_ALIAS;
275 if (dgawin->changeMask & DGA_CHANGE_MBUFSET) {
276 dgawin->changeMask |= DGA_CHANGE_SITE;
277 dgawin->siteChgReason = DGA_SITECHG_MB;
288 dgai_mbsmemb_notify (_Dga_window dgawin)
291 if (dgawin->changeMask & DGA_CHANGE_MBUFSET) {
292 dgai_mbsmemb_notifyMbChg(dgawin);
295 if (dgawin->changeMask & DGA_CHANGE_SITE) {
296 dgai_mbsmemb_notifySiteChg(dgawin);
299 if (dgawin->changeMask & DGA_CHANGE_OVLSTATE) {
300 dgai_mbsmemb_notifyOvlState(dgawin);
308 dgai_mbsmemb_devinfo_update(_Dga_window dgawin)
310 if (!DGA_LOCKSUBJ_VALID(dgawin, dgawin->eLockSubj) ||
311 dgawin->changeMask & DGA_CHANGE_ZOMBIE) {
315 if (DGA_LOCKSUBJ_WINDOW(dgawin, dgawin->eLockSubj)) {
317 if (dgawin->c_devinfoseq != *dgawin->s_devinfoseq_p) {
318 dgawin->changeMask |= DGA_CHANGE_DEVINFO;
319 dgawin->c_devinfoseq = *dgawin->s_devinfoseq_p;
321 } else if (!DGA_LOCKSUBJ_VIEWABLE(dgawin, dgawin->eLockSubj)) {
323 dgai_nmbuf_devinfo_update(dgawin);
330 dgai_mbsmemb_notifySiteChg (_Dga_window dgawin)
332 if (dgawin->siteNotifyFunc) {
333 (*dgawin->siteNotifyFunc)((Dga_drawable)dgawin, dgawin->eLockSubj,
334 dgawin->siteNotifyClientData,
335 dgawin->siteChgReason);
336 dgawin->changeMask &= ~DGA_CHANGE_SITE;
337 dgawin->siteChgReason = DGA_SITECHG_UNKNOWN;
345 dgai_mbsmemb_notifyMbChg (_Dga_window dgawin)
348 if (!dgawin->prevWasMbuffered && dgawin->pMbs) {
349 dgawin->mbChgReason = DGA_MBCHG_ACTIVATION;
350 } else if (dgawin->prevWasMbuffered && !dgawin->pMbs) {
351 dgawin->mbChgReason = DGA_MBCHG_DEACTIVATION;
352 } else if (dgawin->prevWasMbuffered && dgawin->pMbs) {
353 dgawin->mbChgReason = DGA_MBCHG_REPLACEMENT;
358 dgawin->changeMask &= ~DGA_CHANGE_MBUFSET;
359 dgawin->mbChgReason = DGA_MBCHG_UNKNOWN;
363 if (dgawin->mbNotifyFunc) {
364 (*dgawin->mbNotifyFunc)((Dga_drawable)dgawin,
365 dgawin->mbNotifyClientData,
366 dgawin->mbChgReason);
367 dgawin->changeMask &= ~DGA_CHANGE_MBUFSET;
368 dgawin->mbChgReason = DGA_MBCHG_UNKNOWN;
376 dgai_mbsmemb_notifyOvlState (_Dga_window dgawin)
378 if (dgawin->ovlStateNotifyFunc) {
379 (*dgawin->ovlStateNotifyFunc)((Dga_drawable)dgawin,
380 dgawin->ovlStateNotifyClientData,
381 dgawin->c_ovlstate);
382 dgawin->changeMask &= ~DGA_CHANGE_OVLSTATE;