Very early KDE 6 release.

This commit is contained in:
wackyideas 2024-08-09 03:20:25 +02:00
parent 7cc4ccabbc
commit 686046d4f7
6272 changed files with 140920 additions and 529657 deletions

View file

@ -0,0 +1,48 @@
/*
SPDX-FileCopyrightText: 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.15
import QtQuick.Controls 2.3
import org.kde.plasma.core 2.0 as PlasmaCore
TextField {
id: root
signal clicked
activeFocusOnTab: true
Keys.priority: Keys.AfterItem
Keys.onPressed: (event) => {
if(event.key == Qt.Key_Return) {
root.clicked();
}
}
onAccepted: {
root.clicked();
}
color: "black"
padding: 4
background: Rectangle {
color: "#2c628b"
radius: 3
implicitWidth: 100
implicitHeight: 24
border.color: "#7FFFFFFF"
border.width: 1
Rectangle {
anchors.fill: parent
anchors.margins: 1
color: "white"
radius: 2
implicitWidth: 100
implicitHeight: 24
border.color: "#2c628b"
border.width: 1
}
}
}

View file

@ -0,0 +1,30 @@
/*
SPDX-FileCopyrightText: 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.0
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 3.0 as PlasmaComponents3
GenericButton {
id: root
implicitWidth: 38
implicitHeight: 28
focusPolicy: Qt.NoFocus
iconSource: "access"
/*PlasmaCore.IconItem {
id: elementIcon
anchors.centerIn: root
width: PlasmaCore.Units.iconSizes.smallMedium
height: width
animated: false
usesPlasmaTheme: false
source: "access"
}*/
}

View file

@ -0,0 +1,87 @@
import QtQuick 2.4
import QtQuick.Controls 2.15
import QtQuick.Layouts 1.1
import QtQuick.Window 2.1
import Qt5Compat.GraphicalEffects
import org.kde.kirigami 2.20 as Kirigami
import org.kde.ksvg as KSvg
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 3.0 as PlasmaComponents
import org.kde.plasma.extras 2.0 as PlasmaExtras
Control {
id: genericButton
signal clicked
property string text: "";
property var iconSource: "";
property int iconSize: Kirigami.Units.iconSizes.smallMedium;
property alias label: btnLabel
Keys.priority: Keys.AfterItem
Keys.onPressed: (event) => {
if(event.key == Qt.Key_Return) {
genericButton.clicked();
}
}
KSvg.FrameSvgItem {
id: texture
z: -1
anchors.fill: parent
imagePath: Qt.resolvedUrl("../images/button.svg");
prefix: {
var result = "";
if(genericButton.focus) result = "focus-";
if(buttonMA.containsPress) result = "pressed";
else if(buttonMA.containsMouse) result += "hover";
else result += "normal";
return result;
}
}
MouseArea {
id: buttonMA
z: 99
anchors.fill: parent
hoverEnabled: true
acceptedButtons: Qt.LeftButton;
onClicked: {
genericButton.clicked();
}
}
Kirigami.Icon {
id: btnIcon
z: 0
anchors.centerIn: genericButton
width: genericButton.iconSize
height: width
animated: false
//usesPlasmaTheme: false
source: genericButton.iconSource
visible: genericButton.iconSource !== ""
}
PlasmaComponents.Label {
id: btnLabel
z: 0
anchors.fill: parent
text: genericButton.text
visible: genericButton.text !== ""
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
elide: Text.ElideRight
renderType: Text.NativeRendering
font.hintingPreference: Font.PreferFullHinting
font.kerning: false
layer.enabled: genericButton.text !== ""
layer.effect: DropShadow {
//visible: !softwareRendering
horizontalOffset: 0
verticalOffset: 1
radius: 6
samples: 14
spread: 0.0001
color: "#bf000000"
}
}
}

View file

@ -0,0 +1,25 @@
/*
SPDX-FileCopyrightText: 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.15
import org.kde.plasma.components 3.0 as PlasmaComponents3
Image {
id: root
property alias containsMouse: mouseArea.containsMouse
signal clicked
activeFocusOnTab: true
source: mouseArea.containsPress ? "../images/gopressed.png" : (activeFocus || containsMouse ? "../images/gohover.png" : "../images/go.png")
MouseArea {
id: mouseArea
hoverEnabled: true
onClicked: root.clicked()
anchors.fill: parent
}
}

View file

@ -0,0 +1,22 @@
/*
SPDX-FileCopyrightText: 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.0
import org.kde.plasma.components 3.0 as PlasmaComponents3
GenericButton {
id: root
implicitWidth: 45
implicitHeight: 28
focusPolicy: Qt.TabFocus
Accessible.description: i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "Button to show/hide virtual keyboard", "Virtual Keyboard")
//iconSource: "../images/osk.png"
Image {
anchors.centerIn: root
source: "../images/osk.png"
}
}

View file

@ -0,0 +1,64 @@
/*
SPDX-FileCopyrightText: 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.0
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 3.0 as PlasmaComponents3
import org.kde.kirigami 2.20 as Kirigami
import Qt5Compat.GraphicalEffects
Item {
id: root
property string avatarPath
property string iconSource: "user-symbolic"
implicitWidth: 190
implicitHeight: 190
Item {
id: imageSource
anchors.centerIn: root
width: 126
height: 126
Image {
id: face
source: avatarPath
fillMode: Image.PreserveAspectCrop
anchors.fill: parent
}
LinearGradient {
id: gradient
anchors.fill: parent
z: -1
start: Qt.point(0,0)
end: Qt.point(gradient.width, gradient.height)
gradient: Gradient {
GradientStop { position: 0.0; color: "#eeecee" }
GradientStop { position: 1.0; color: "#a39ea3" }
}
}
Kirigami.Icon {
id: faceIcon
source: iconSource
visible: (face.status == Image.Error || face.status == Image.Null)
anchors.fill: parent
anchors.margins: Kirigami.Units.gridUnit * 0.5 // because mockup says so...
//colorGroup: PlasmaCore.ColorScope.colorGroup
}
}
Image {
id: imageFrame
anchors.fill: root
source: "../images/pfpframe.png"
}
}

View file

@ -0,0 +1,53 @@
/*
SPDX-FileCopyrightText: 2016 David Edmundson <davidedmundson@kde.org>
SPDX-License-Identifier: LGPL-2.0-or-later
*/
import QtQuick 2.15
import QtQuick.Layouts 1.1
import QtQuick.Controls 2.15
import Qt5Compat.GraphicalEffects
RowLayout {
id: root
property string statusText
property int spinnum: 0
property bool speen
spacing: 8
Image {
id: loadingspinner
source: "../images/100/spin"+spinnum+".png"
}
Label {
id: welcomeLbl
z: 1
text: statusText
color: "#FFFFFF"
font.pointSize: 18
renderType: Text.NativeRendering
font.hintingPreference: Font.PreferFullHinting
font.kerning: false
layer.enabled: true
layer.effect: DropShadow {
//visible: !softwareRendering
horizontalOffset: 0
verticalOffset: 1
radius: 6
samples: 14
spread: 0.0001
color: "#bf000000"
}
}
SequentialAnimation {
id: spinner
running: speen
loops: Animation.Infinite
NumberAnimation { target: root; property: "spinnum"; to: 17; duration: 900 }
NumberAnimation { target: root; property: "spinnum"; to: 0; duration: 0 }
}
}

View file

@ -0,0 +1,72 @@
/*
SPDX-FileCopyrightText: 2017 Martin Gräßlin <mgraesslin@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.15
import QtQuick.VirtualKeyboard 2.4
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.kirigami 2.20 as Kirigami
InputPanel {
id: inputPanel
property bool activated: false
active: activated && Qt.inputMethod.visible
width: parent.width
states: [
State {
name: "visible"
when: inputPanel.active
PropertyChanges {
target: inputPanel
y: inputPanel.parent.height - inputPanel.height
opacity: 1
visible: true
}
},
State {
name: "hidden"
when: !inputPanel.active
PropertyChanges {
target: inputPanel
y: inputPanel.parent.height
opacity: 0
visible:false
}
}
]
transitions: [
Transition {
to: "visible"
ParallelAnimation {
YAnimator {
// NOTE this is necessary as otherwise the keyboard always starts the transition with Y as 0, due to the internal reparenting happening when becomes active
from: inputPanel.parent.height
duration: Kirigami.Units.longDuration
easing.type: Easing.OutQuad
}
OpacityAnimator {
duration: Kirigami.Units.longDuration
easing.type: Easing.OutQuad
}
}
},
Transition {
to: "hidden"
ParallelAnimation {
YAnimator {
duration: Kirigami.Units.longDuration
easing.type: Easing.InQuad
}
OpacityAnimator {
duration: Kirigami.Units.longDuration
easing.type: Easing.InQuad
}
}
}
]
}

View file

@ -0,0 +1,25 @@
/*
SPDX-FileCopyrightText: 2021 Aleix Pol Gonzalez <aleixpol@kde.org>
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
*/
import QtQuick 2.15
import org.kde.plasma.workspace.keyboardlayout 1.0 as Keyboards
Item {
id: inputPanel
readonly property bool active: Keyboards.KWinVirtualKeyboard.visible
property bool activated: false
visible: Keyboards.KWinVirtualKeyboard.visible
x: Qt.inputMethod.keyboardRectangle.x
y: Qt.inputMethod.keyboardRectangle.y
height: Qt.inputMethod.keyboardRectangle.height
width: Qt.inputMethod.keyboardRectangle.width
onActivatedChanged: if (activated) {
Keyboards.KWinVirtualKeyboard.enabled = true
}
}

View file

@ -0,0 +1,23 @@
[kcminputrc][Mouse]
cursorTheme=aero-cursors
[kdeglobals][General]
ColorScheme=AeroColorScheme
[kdeglobals][Icons]
Theme=windowsicon
[kdeglobals][KDE]
widgetStyle=kvantum
[kwinrc][DesktopSwitcher]
LayoutName=org.kde.breeze.desktop
[kwinrc][WindowSwitcher]
LayoutName=thumbnail_seven
[plasmarc][Theme]
name=Seven-Black
[KSplash]
Theme=authui7

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 118 KiB

File diff suppressed because it is too large Load diff

After

Width:  |  Height:  |  Size: 98 KiB

View file

@ -0,0 +1,25 @@
#!/usr/bin/python3
from PIL import Image
import glob
import os
os.system("mogrify -format png Bitmap5004.bmp")
img = Image.open('Bitmap5004.png')
w, h = img.size
framesize = min(w, h)
horizontalframes = (w > h)
fin = False
cropcount = 0
while fin == False:
if (horizontalframes and framesize * (cropcount+1) > w) or (not horizontalframes and framesize * (cropcount+1) > h):
print("e")
fin = True
break
if horizontalframes:
img.crop((framesize * cropcount, 0, framesize * (cropcount+1), framesize)).save('spin'+str(cropcount)+'.png')
else:
img.crop((0, framesize * cropcount, framesize, framesize * (cropcount+1))).save('spin'+str(cropcount)+'.png')
cropcount += 1

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.1 KiB

View file

@ -0,0 +1,280 @@
/*
SPDX-FileCopyrightText: 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.2
import QtQuick.Layouts 1.2
import QtQuick.Controls 2.12 as QQC2
import org.kde.plasma.components 3.0 as PlasmaComponents
import org.kde.coreaddons 1.0 as KCoreAddons
import org.kde.kirigami 2.20 as Kirigami
import org.kde.breeze.components
import "timer.js" as AutoTriggerTimer
import org.kde.plasma.private.sessions 2.0
Item {
id: root
Kirigami.Theme.inherit: false
Kirigami.Theme.colorSet: Kirigami.Theme.Complementary
height: screenGeometry.height
width: screenGeometry.width
signal logoutRequested()
signal haltRequested()
signal suspendRequested(int spdMethod)
signal rebootRequested()
signal rebootRequested2(int opt)
signal cancelRequested()
signal lockScreenRequested()
signal cancelSoftwareUpdateRequested()
property alias backgroundColor: backgroundRect.color
function sleepRequested() {
root.suspendRequested(2);
}
function hibernateRequested() {
root.suspendRequested(4);
}
property real timeout: 30
property real remainingTime: root.timeout
property var currentAction: {
switch (sdtype) {
case ShutdownType.ShutdownTypeReboot:
return () => root.rebootRequested();
case ShutdownType.ShutdownTypeHalt:
return () => root.haltRequested();
default:
return () => root.logoutRequested();
}
}
readonly property bool showAllOptions: sdtype === ShutdownType.ShutdownTypeDefault
KCoreAddons.KUser {
id: kuser
}
// For showing a "other users are logged in" hint
SessionsModel {
id: sessionsModel
includeUnusedSessions: false
}
QQC2.Action {
onTriggered: root.cancelRequested()
shortcut: "Escape"
}
onRemainingTimeChanged: {
if (remainingTime <= 0) {
(root.currentAction)();
}
}
Timer {
id: countDownTimer
running: !root.showAllOptions
repeat: true
interval: 1000
onTriggered: remainingTime--
Component.onCompleted: {
AutoTriggerTimer.addCancelAutoTriggerCallback(function() {
countDownTimer.running = false;
});
}
}
function isLightColor(color) {
return Math.max(color.r, color.g, color.b) > 0.5
}
Rectangle {
id: backgroundRect
anchors.fill: parent
//use "black" because this is intended to look like a general darkening of the scene. a dark gray as normal background would just look too "washed out"
color: root.isLightColor(Kirigami.Theme.backgroundColor) ? Kirigami.Theme.backgroundColor : "black"
opacity: 0.5
}
MouseArea {
anchors.fill: parent
onClicked: root.cancelRequested()
}
UserDelegate {
width: Kirigami.Units.gridUnit * 8
height: Kirigami.Units.gridUnit * 9
anchors {
horizontalCenter: parent.horizontalCenter
bottom: parent.verticalCenter
}
constrainText: false
avatarPath: kuser.faceIconUrl
iconSource: "user-identity"
isCurrent: true
name: kuser.fullName
}
ColumnLayout {
id: column
anchors {
top: parent.verticalCenter
topMargin: Kirigami.Units.gridUnit * 2
horizontalCenter: parent.horizontalCenter
}
spacing: Kirigami.Units.largeSpacing
height: Math.max(implicitHeight, Kirigami.Units.gridUnit * 10)
width: Math.max(implicitWidth, Kirigami.Units.gridUnit * 16)
PlasmaComponents.Label {
font.pointSize: Kirigami.Theme.defaultFont.pointSize + 1
Layout.alignment: Qt.AlignHCenter
//opacity, as visible would re-layout
opacity: countDownTimer.running ? 1 : 0
Behavior on opacity {
OpacityAnimator {
duration: Kirigami.Units.longDuration
easing.type: Easing.InOutQuad
}
}
text: {
switch (sdtype) {
case ShutdownType.ShutdownTypeReboot:
return softwareUpdatePending ? i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Installing software updates and restarting in 1 second", "Installing software updates and restarting in %1 seconds", root.remainingTime)
: i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Restarting in 1 second", "Restarting in %1 seconds", root.remainingTime);
case ShutdownType.ShutdownTypeNone:
return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Logging out in 1 second", "Logging out in %1 seconds", root.remainingTime);
case ShutdownType.ShutdownTypeHalt:
default:
return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Shutting down in 1 second", "Shutting down in %1 seconds", root.remainingTime);
}
}
textFormat: Text.PlainText
}
PlasmaComponents.Label {
font.pointSize: Kirigami.Theme.defaultFont.pointSize + 1
Layout.maximumWidth: Math.max(Kirigami.Units.gridUnit * 16, logoutButtonsRow.implicitWidth)
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
horizontalAlignment: Text.AlignHCenter
wrapMode: Text.WordWrap
font.italic: true
text: i18ndp("plasma_lookandfeel_org.kde.lookandfeel",
"One other user is currently logged in. If the computer is shut down or restarted, that user may lose work.",
"%1 other users are currently logged in. If the computer is shut down or restarted, those users may lose work.",
sessionsModel.count - 1)
textFormat: Text.PlainText
visible: sessionsModel.count > 1
}
PlasmaComponents.Label {
font.pointSize: Kirigami.Theme.defaultFont.pointSize + 1
Layout.maximumWidth: Math.max(Kirigami.Units.gridUnit * 16, logoutButtonsRow.implicitWidth)
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
horizontalAlignment: Text.AlignHCenter
wrapMode: Text.WordWrap
font.italic: true
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "When restarted, the computer will enter the firmware setup screen.")
textFormat: Text.PlainText
visible: rebootToFirmwareSetup
}
RowLayout {
id: logoutButtonsRow
spacing: Kirigami.Units.gridUnit * 2
Layout.topMargin: Kirigami.Units.gridUnit * 2 - column.spacing
Layout.alignment: Qt.AlignHCenter
LogoutButton {
id: suspendButton
iconSource: "system-suspend"
text: root.showAllOptions ? i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "Suspend to RAM", "Sleep")
: i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "Suspend to RAM", "Sleep Now")
onClicked: root.sleepRequested()
KeyNavigation.left: cancelButton
KeyNavigation.right: hibernateButton.visible ? hibernateButton : (rebootButton.visible ? rebootButton : (shutdownButton.visible ? shutdownButton : (logoutButton.visible ? logoutButton : cancelButton)))
visible: spdMethods.SuspendState && root.showAllOptions
}
LogoutButton {
id: hibernateButton
iconSource: "system-suspend-hibernate"
text: root.showAllOptions ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Hibernate")
: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Hibernate Now")
onClicked: root.hibernateRequested()
KeyNavigation.left: suspendButton.visible ? suspendButton : cancelButton
KeyNavigation.right: rebootButton.visible ? rebootButton : (shutdownButton.visible ? shutdownButton : (logoutButton.visible ? logoutButton : cancelButton))
visible: spdMethods.HibernateState && root.showAllOptions
}
LogoutButton {
id: rebootButton
iconSource: softwareUpdatePending ? "update-none" : "system-reboot"
text: {
if (softwareUpdatePending) {
return root.showAllOptions ? i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "@action:button Keep short", "Install Updates & Restart")
: i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "@action:button Keep short", "Install Updates & Restart Now")
} else {
return root.showAllOptions ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Restart")
: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Restart Now")
}
}
onClicked: root.rebootRequested()
KeyNavigation.left: hibernateButton.visible ? hibernateButton : (suspendButton.visible ? suspendButton : cancelButton)
KeyNavigation.right: rebootWithoutUpdatesButton.visible ? rebootWithoutUpdatesButton : (shutdownButton.visible ? shutdownButton : (logoutButton.visible ? logoutButton : cancelButton))
focus: sdtype === ShutdownType.ShutdownTypeReboot
visible: maysd && (sdtype === ShutdownType.ShutdownTypeReboot || root.showAllOptions)
}
LogoutButton {
id: rebootWithoutUpdatesButton
iconSource: "system-reboot"
text: root.showAllOptions ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Restart")
: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Restart Now")
onClicked: {
root.cancelSoftwareUpdateRequested()
root.rebootRequested()
}
KeyNavigation.left: rebootButton
KeyNavigation.right: shutdownButton.visible ? shutdownButton : (logoutButton.visible ? logoutButton : cancelButton)
visible: maysd && softwareUpdatePending && (sdtype === ShutdownType.ShutdownTypeReboot || root.showAllOptions)
}
LogoutButton {
id: shutdownButton
iconSource: "system-shutdown"
text: root.showAllOptions ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Shut Down")
: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Shut Down Now")
onClicked: root.haltRequested()
KeyNavigation.left: rebootWithoutUpdatesButton.visible ? rebootWithoutUpdatesButton : (rebootButton.visible ? rebootButton : (hibernateButton.visible ? hibernateButton : (suspendButton.visible ? suspendButton : cancelButton)))
KeyNavigation.right: logoutButton.visible ? logoutButton : cancelButton
focus: sdtype === ShutdownType.ShutdownTypeHalt || root.showAllOptions
visible: maysd && (sdtype === ShutdownType.ShutdownTypeHalt || root.showAllOptions)
}
LogoutButton {
id: logoutButton
iconSource: "system-log-out"
text: root.showAllOptions ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Log Out")
: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Log Out Now")
onClicked: root.logoutRequested()
KeyNavigation.left: shutdownButton.visible ? shutdownButton : (rebootWithoutUpdatesButton.visible ? rebootWithoutUpdatesButton : (rebootButton.visible ? rebootButton : (hibernateButton.visible ? hibernateButton : (suspendButton.visible ? suspendButton : cancelButton))))
KeyNavigation.right: cancelButton
focus: sdtype === ShutdownType.ShutdownTypeNone
visible: canLogout && (sdtype === ShutdownType.ShutdownTypeNone || root.showAllOptions)
}
LogoutButton {
id: cancelButton
iconSource: "dialog-cancel"
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Cancel")
onClicked: root.cancelRequested()
KeyNavigation.left: logoutButton.visible ? logoutButton : (shutdownButton.visible ? shutdownButton : (rebootWithoutUpdatesButton.visible ? rebootWithoutUpdatesButton : (rebootButton.visible ? rebootButton : (hibernateButton.visible ? hibernateButton : suspendButton))))
KeyNavigation.right: suspendButton.visible ? suspendButton : (hibernateButton.visible ? hibernateButton : rebootButton)
}
}
}
}

View file

@ -0,0 +1,37 @@
/*
SPDX-FileCopyrightText: 2016 Marco Martin <mart@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
import QtQuick 2.2
import QtQuick.Layouts 1.2
import org.kde.kirigami 2.20 as Kirigami
import org.kde.breeze.components
import "timer.js" as AutoTriggerTimer
ActionButton {
Layout.alignment: Qt.AlignTop
iconSize: Kirigami.Units.iconSizes.huge
labelRendering: Text.QtRendering // Remove once we've solved Qt bug: https://bugreports.qt.io/browse/QTBUG-70138 (KDE bug: https://bugs.kde.org/show_bug.cgi?id=401644)
font.underline: false
font.pointSize: Kirigami.Theme.defaultFont.pointSize + 1
circleVisiblity: activeFocus || containsMouse
circleOpacity: 0.15 // Selected option's circle is instantly visible
opacity: activeFocus || containsMouse ? 1 : 0.5
Behavior on opacity {
PropertyAnimation { // OpacityAnimator makes it turn black at random intervals
duration: Kirigami.Units.longDuration
easing.type: Easing.InOutQuad
}
}
Keys.onPressed: {
AutoTriggerTimer.cancelAutoTrigger();
}
}

View file

@ -0,0 +1,26 @@
/*
SPDX-FileCopyrightText: 2018 David Edmundson <davidedmundson@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
.pragma library
//written as a library to share knowledge of when a key was pressed
//between the multiple views, so pressing a key on one cancels all timers
var callbacks = [];
function addCancelAutoTriggerCallback(callback) {
callbacks.push(callback);
}
function cancelAutoTrigger() {
callbacks.forEach(function(c) {
if (!c) {
return;
}
c();
});
}

Binary file not shown.

View file

@ -0,0 +1,101 @@
/*
* Copyright 2014 Marco Martin <mart@kde.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2,
* or (at your option) any later version, as published by the Free
* Software Foundation
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details
*
* You should have received a copy of the GNU General Public
* License along with this program; if not, write to the
* Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
import QtQuick 2.15
import QtQuick.Layouts 1.1
import QtQuick.Controls 2.3
import QtQuick.Templates 2.3
import org.kde.plasma.core 2.0 as PlasmaCore
import QtMultimedia
import "../components"
Item {
id: root
z: -9
property int stage
onStageChanged: {
if (stage == 5) {
//lockSuccess.play();
//fadeOut.running = true;
transitionAnim.opacity = 1;
}
}
/*MediaPlayer {
id: lockSuccess
source: Qt.resolvedUrl("../sounds/lockSuccess.ogg");
audioOutput: AudioOutput {}
}*/
Rectangle {
color: "#1D5F7A"
anchors.fill: parent
}
Image {
id: bgtexture
source: "../images/bgtexture.jpg"
anchors.fill: parent
}
Status {
id: statusText
anchors.centerIn: parent
anchors.verticalCenterOffset: -36
statusText: i18nd("okular", "Welcome")
speen: true
}
RowLayout {
anchors {
bottom: parent.bottom
left: parent.left
right: parent.right
}
height: 96
Rectangle { Layout.fillWidth: true }
Image {
id: watermark
source: "../images/watermark.png"
}
Rectangle { Layout.fillWidth: true }
}
Rectangle {
id: transitionAnim
opacity: 0
color: "black"
anchors.fill: parent
Behavior on opacity {
NumberAnimation { duration: 640; }
}
}
/*OpacityAnimator {
id: fadeOut
running: false
target: transitionAnim
from: 0
to: 1
duration: 640
easing.type: Easing.InOutQuad
}*/
}