Warning, /plasma/plasma-mobile/look-and-feel/contents/lockscreen/LockScreenWideScreenContent.qml is written in an unsupported language. File is not indexed.

0001 /*
0002  * SPDX-FileCopyrightText: 2021-2022 Devin Lin <espidev@gmail.com>
0003  * SPDX-License-Identifier: GPL-2.0-or-later
0004  */
0005 
0006 import QtQuick 2.12
0007 import QtQuick.Layouts 1.1
0008 
0009 import org.kde.plasma.core 2.0 as PlasmaCore
0010 import org.kde.plasma.workspace.keyboardlayout 1.0
0011 import org.kde.notificationmanager 1.1 as Notifications
0012 import org.kde.plasma.private.mobileshell 1.0 as MobileShell
0013 
0014 Loader {
0015     id: root
0016     
0017     required property var lockScreenState
0018     property var notificationsModel: []
0019     
0020     property bool notificationsShown: false
0021     
0022     signal passwordRequested()
0023     
0024     asynchronous: true
0025     sourceComponent: Item {
0026         Item {
0027             id: clock
0028             width: parent.width / 2   
0029             anchors {
0030                 top: parent.top
0031                 bottom: parent.bottom
0032                 left: parent.left
0033                 leftMargin: PlasmaCore.Units.gridUnit * 3
0034             }
0035             
0036             ColumnLayout {
0037                 id: tabletLayout
0038                 anchors.centerIn: parent
0039                 spacing: PlasmaCore.Units.gridUnit
0040                 
0041                 Clock {
0042                     layoutAlignment: Qt.AlignLeft
0043                     Layout.alignment: Qt.AlignLeft
0044                     Layout.fillWidth: true
0045                     Layout.minimumWidth: PlasmaCore.Units.gridUnit * 20
0046                 }
0047                 
0048                 MobileShell.MediaControlsWidget {
0049                     Layout.alignment: Qt.AlignLeft
0050                     Layout.fillWidth: true
0051                     Layout.maximumWidth: PlasmaCore.Units.gridUnit * 25
0052                 }
0053             }
0054         }
0055             
0056         // tablet notifications list
0057         ColumnLayout {
0058             id: tabletNotificationsList
0059             anchors {
0060                 top: parent.top
0061                 bottom: parent.bottom
0062                 left: clock.right
0063                 right: parent.right
0064                 rightMargin: PlasmaCore.Units.gridUnit
0065             }
0066             
0067             NotificationsComponent {
0068                 id: notificationComponent
0069                 lockScreenState: root.lockScreenState
0070                 notificationsModel: root.notificationsModel
0071                 
0072                 Layout.alignment: Qt.AlignVCenter | Qt.AlignHCenter
0073                 Layout.fillWidth: true
0074                 Layout.fillHeight: true
0075                 Layout.topMargin: PlasmaCore.Units.gridUnit * 2
0076                 Layout.bottomMargin: PlasmaCore.Units.gridUnit
0077                 Layout.minimumWidth: PlasmaCore.Units.gridUnit * 15
0078                 Layout.maximumWidth: PlasmaCore.Units.gridUnit * 25
0079                 
0080                 leftMargin: PlasmaCore.Units.gridUnit
0081                 rightMargin: PlasmaCore.Units.gridUnit
0082                 bottomMargin: PlasmaCore.Units.gridUnit
0083                 topMargin: PlasmaCore.Units.gridUnit
0084                 
0085                 onPasswordRequested: root.passwordRequested()
0086                 onNotificationsShownChanged: root.notificationsShown = notificationsShown
0087             }
0088         }
0089     }
0090 }