Warning, /plasma/plasma-desktop/kcms/tablet/ui/Output.qml is written in an unsupported language. File is not indexed.
0001 /*
0002 SPDX-FileCopyrightText: 2019 Roman Gilg <subdiff@gmail.com>
0003 SPDX-FileCopyrightText: 2012 Dan Vratil <dvratil@redhat.com>
0004
0005 SPDX-License-Identifier: GPL-2.0-or-later
0006
0007 Adapted from KScreen
0008 */
0009 import QtQuick 2.15
0010 import QtQuick.Layouts 1.15
0011 import Qt5Compat.GraphicalEffects
0012 import org.kde.kirigami 2.20 as Kirigami
0013
0014 Item {
0015 id: output
0016
0017 property bool isSelected: true
0018
0019 onIsSelectedChanged: {
0020 if (isSelected) {
0021 z = 89;
0022 } else {
0023 z = 0;
0024 }
0025 }
0026
0027 Rectangle {
0028 id: outline
0029 radius: Kirigami.Units.smallSpacing
0030 color: Kirigami.Theme.backgroundColor
0031
0032 anchors.fill: parent
0033
0034 border {
0035 color: isSelected ? Kirigami.Theme.highlightColor : Kirigami.Theme.disabledTextColor
0036 width: 1
0037
0038 ColorAnimation on color {
0039 duration: Kirigami.Units.longDuration
0040 }
0041 }
0042 }
0043
0044 Item {
0045 id: orientationPanelContainer
0046
0047 anchors.fill: output
0048 visible: false
0049
0050 Rectangle {
0051 id: orientationPanel
0052 anchors {
0053 left: parent.left
0054 right: parent.right
0055 bottom: parent.bottom
0056 }
0057
0058 height: Kirigami.Units.largeSpacing
0059 color: isSelected ? Kirigami.Theme.highlightColor : Kirigami.Theme.disabledTextColor
0060 smooth: true
0061
0062 ColorAnimation on color {
0063 duration: Kirigami.Units.longDuration
0064 }
0065 }
0066 }
0067
0068 OpacityMask {
0069 anchors.fill: orientationPanelContainer
0070 source: orientationPanelContainer
0071 maskSource: outline
0072 }
0073 }
0074