Skip to content

taskmanager: Only update the task label when visible

When the task label is not visible, we should not bind text to model.display.

This is expected to slightly reduce the power consumption in daily usage.

BUG: 414121

Before After
before-visible after-visible

Test QML program:

import QtQuick 2.15
import QtQuick.Window 2.15
import QtQuick.Controls 2.15

Window {
    id: root
    width: 640
    height: 480
    visible: true
    title: qsTr("Hello World")
    Timer {
        id: timer
        interval: 50
        running: true
        repeat: true
        onTriggered: root.title = Math.random()
    }
}
Edited by Fushan Wen

Merge request reports