icon: repaint dock dots after tile/appearance observer notifications
On Wayland there are no Expose events, so when tileObserver or appearanceObserver repaints an icon (via update_icon_pixmap or window_clear), the dock dots drawn by appicon_paint_dock_dots were lost. Explicitly re-trigger dock dots painting for docked appicons after the observer repaint.
This commit is contained in:
parent
6611dd4853
commit
c982a29d2f
20
src/icon.c
20
src/icon.c
|
|
@ -85,6 +85,16 @@ static void appearanceObserver(void *self, WMNotification *notif)
|
|||
/* so that the appicon expose handlers will paint the appicon specific
|
||||
* stuff */
|
||||
wm_backend->window_clear(icon->core->window);
|
||||
|
||||
/* Repaint dock dots (no Expose events on Wayland). */
|
||||
if (icon->core->descriptor.parent_type == WCLASS_APPICON) {
|
||||
WAppIcon *aicon = icon->core->descriptor.parent;
|
||||
if (aicon && aicon->docked) {
|
||||
WApplication *wapp = icon->owner ?
|
||||
wApplicationOf(icon->owner->main_window) : NULL;
|
||||
wm_backend->appicon_paint_dock_dots(aicon, wapp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void tileObserver(void *self, WMNotification *notif)
|
||||
|
|
@ -103,6 +113,16 @@ static void tileObserver(void *self, WMNotification *notif)
|
|||
if (scr->clip_icon && scr->clip_icon->icon == icon) {
|
||||
wClipIconPaint(scr->clip_icon);
|
||||
}
|
||||
|
||||
/* For docked appicons, repaint dock dots (no Expose on Wayland). */
|
||||
if (icon->core->descriptor.parent_type == WCLASS_APPICON) {
|
||||
WAppIcon *aicon = icon->core->descriptor.parent;
|
||||
if (aicon && aicon->docked) {
|
||||
WApplication *wapp = icon->owner ?
|
||||
wApplicationOf(icon->owner->main_window) : NULL;
|
||||
wm_backend->appicon_paint_dock_dots(aicon, wapp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/************************************/
|
||||
|
|
|
|||
Loading…
Reference in New Issue