Changeset View
Changeset View
Standalone View
Standalone View
src/client/plasmashell.cpp
Show First 20 Lines • Show All 274 Lines • ▼ Show 20 Line(s) | 274 | case Role::OnScreenDisplay: | |||
---|---|---|---|---|---|
275 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_ONSCREENDISPLAY; | 275 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_ONSCREENDISPLAY; | ||
276 | break; | 276 | break; | ||
277 | case Role::Notification: | 277 | case Role::Notification: | ||
278 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_NOTIFICATION; | 278 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_NOTIFICATION; | ||
279 | break; | 279 | break; | ||
280 | case Role::ToolTip: | 280 | case Role::ToolTip: | ||
281 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_TOOLTIP; | 281 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_TOOLTIP; | ||
282 | break; | 282 | break; | ||
283 | case Role::CriticalNotification: | ||||
284 | if (wl_proxy_get_version(d->surface) < ORG_KDE_PLASMA_SURFACE_ROLE_CRITICALNOTIFICATION_SINCE_VERSION) { | ||||
285 | // Fall back to generic notification type if not supported | ||||
286 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_NOTIFICATION; | ||||
287 | } else { | ||||
288 | wlRole = ORG_KDE_PLASMA_SURFACE_ROLE_CRITICALNOTIFICATION; | ||||
289 | } | ||||
290 | break; | ||||
283 | default: | 291 | default: | ||
284 | Q_UNREACHABLE(); | 292 | Q_UNREACHABLE(); | ||
285 | break; | 293 | break; | ||
286 | } | 294 | } | ||
287 | org_kde_plasma_surface_set_role(d->surface, wlRole); | 295 | org_kde_plasma_surface_set_role(d->surface, wlRole); | ||
288 | d->role = role; | 296 | d->role = role; | ||
289 | } | 297 | } | ||
290 | 298 | | |||
▲ Show 20 Lines • Show All 56 Lines • Show Last 20 Lines |