mirror of
https://github.com/noctalia-dev/noctalia-shell.git
synced 2026-05-11 17:08:27 +08:00
NWaveSpectrum: avoid error if context not ready yet
This commit is contained in:
@@ -38,7 +38,8 @@ Item {
|
||||
onRenderingActiveChanged: {
|
||||
if (!renderingActive) {
|
||||
var ctx = canvas.getContext("2d")
|
||||
ctx.reset()
|
||||
if (ctx)
|
||||
ctx.reset()
|
||||
canvas.requestPaint()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user