Show message and hide controls if no player is available
Summary: Instead of showing empty controls show a message that no players are available Test Plan: Use eyes Reviewers: #kde_connect, apol Reviewed By: #kde_connect, apol Subscribers: kdeconnect Tags: #kde_connect Differential Revision: https://phabricator.kde.org/D12830
This commit is contained in:
parent
a19713fbeb
commit
f094408171
1 changed files with 8 additions and 0 deletions
|
@ -29,9 +29,17 @@ Kirigami.Page
|
|||
property QtObject pluginInterface
|
||||
title: i18n("Multimedia Controls")
|
||||
|
||||
Label {
|
||||
id: noPlayersText
|
||||
text: i18n("No players available")
|
||||
anchors.centerIn: parent
|
||||
visible: pluginInterface.playerList.length == 0
|
||||
}
|
||||
|
||||
ColumnLayout
|
||||
{
|
||||
anchors.fill: parent
|
||||
visible: !noPlayersText.visible
|
||||
|
||||
Component.onCompleted: {
|
||||
pluginInterface.requestPlayerList();
|
||||
|
|
Loading…
Reference in a new issue