diff options
| author | Nippy <nippy@Nippy-Mac-mini.local> | 2026-11-01 18:13:54 +0100 |
|---|---|---|
| committer | Nippy <nippy@Nippy-Mac-mini.local> | 2026-11-01 18:13:54 +0100 |
| commit | a64ef966534f8dba6af889ba4bfce15691bfc85b (patch) | |
| tree | b30f284d05b80fa115569ab220deae13797fad6f /raveos-calamares-theme/etc/calamares/branding/raveos/show.qml | |
| parent | 919f977b40016f588b0c8532c8a57f6035056b95 (diff) | |
| download | RaveOS-PKGBUILD-a64ef966534f8dba6af889ba4bfce15691bfc85b.tar.gz RaveOS-PKGBUILD-a64ef966534f8dba6af889ba4bfce15691bfc85b.zip | |
új telepítő
Diffstat (limited to 'raveos-calamares-theme/etc/calamares/branding/raveos/show.qml')
| -rwxr-xr-x | raveos-calamares-theme/etc/calamares/branding/raveos/show.qml | 295 |
1 files changed, 192 insertions, 103 deletions
diff --git a/raveos-calamares-theme/etc/calamares/branding/raveos/show.qml b/raveos-calamares-theme/etc/calamares/branding/raveos/show.qml index 78142a5..c2c954b 100755 --- a/raveos-calamares-theme/etc/calamares/branding/raveos/show.qml +++ b/raveos-calamares-theme/etc/calamares/branding/raveos/show.qml @@ -1,128 +1,217 @@ -/* === This file is part of Calamares - <https://calamares.io> === - * - * SPDX-FileCopyrightText: 2015 Teo Mrnjavac <teo@kde.org> - * SPDX-FileCopyrightText: 2018 Adriaan de Groot <groot@kde.org> - * SPDX-License-Identifier: GPL-3.0-or-later - * - * Calamares is Free Software: see the License-Identifier above. - * - */ +import io.calamares.core 1.0 -import QtQuick 2.0; -import calamares.slideshow 1.0; +import QtQuick 2.15 +import QtQuick.Controls 2.15 +import QtQuick.Layouts 1.15 +import "RaveOS" -Presentation -{ - id: presentation +Rectangle { + id: bemutato + color: Stilus.hatter - Rectangle { - anchors.fill: parent - color: "#2c3e50" - z: -1 + property bool activatedInCalamares: false + property int aktualis: 0 + property real haladas: 0 + property string uzenet: "" + + readonly property var kepek: [ + { forras: "images/01-updates.png", leiras: qsTr("Start using it, not configuring it. RaveOS only updates when you want it to.") }, + { forras: "images/02-privacy.png", leiras: qsTr("Private for you, secure for you. We do not collect data about you.") }, + { forras: "images/03-filesystem.png", leiras: qsTr("EXT4/BTRFS file system that never fragments.") }, + { forras: "images/04-gaming.png", leiras: qsTr("Optimized for gaming at the deepest levels.") }, + { forras: "images/05-bugreport.png", leiras: qsTr("If something goes wrong, open an issue at git.rp1.hu. Thank you!") }, + { forras: "images/06-team-credits.png", leiras: qsTr("RaveOS Team. Thanks to every beta tester!") } + ] + readonly property int csapatKep: kepek.length - 1 + readonly property bool vegeFele: haladas >= 0.9 + + function frissit() { + haladas = Number(Global.value("raveosHaladas")) || 0 + uzenet = Global.value("raveosUzenet") || "" + if (vegeFele && aktualis !== csapatKep) { + aktualis = csapatKep + } + } + + function lapoz(irany) { + aktualis = (aktualis + irany + kepek.length) % kepek.length + leptetes.restart() + } + + function onActivate() { + activatedInCalamares = true + aktualis = 0 + frissit() } - function nextSlide() { - console.log("QML Component (default slideshow) Next slide"); - presentation.goToNextSlide(); + function onLeave() { + activatedInCalamares = false + } + + Connections { + target: Global + function onChanged() { + Qt.callLater(bemutato.frissit) + } } Timer { - id: advanceTimer - interval: 20000 - running: presentation.activatedInCalamares + id: leptetes + interval: 8000 repeat: true - onTriggered: nextSlide() + running: bemutato.activatedInCalamares && !bemutato.vegeFele + onTriggered: bemutato.aktualis = bemutato.aktualis + 1 >= bemutato.csapatKep ? 0 : bemutato.aktualis + 1 } - Slide { - - anchors.fill: parent - anchors.verticalCenterOffset: 0 + component NyilGomb: Button { + id: gomb + property string ut: "" + Layout.preferredWidth: 40 + Layout.preferredHeight: 40 + padding: 0 + background: Rectangle { + color: gomb.hovered ? Stilus.aktiv : "transparent" + border.width: 1 + border.color: Stilus.keretErosebb + } + contentItem: Canvas { + onPaint: { + var c = getContext("2d") + c.reset() + c.strokeStyle = Stilus.szoveg + c.lineWidth = 2 + c.beginPath() + var x = gomb.ut === "bal" ? [23, 17] : [17, 23] + c.moveTo(x[0], 14) + c.lineTo(x[1], 20) + c.lineTo(x[0], 26) + c.stroke() + } + } + } - Image { - id: background1 - source: "images/2.png" + ColumnLayout { anchors.fill: parent - fillMode: Image.PreserveAspectCrop - smooth: true - mipmap: true - } - } + anchors.topMargin: 16 + anchors.bottomMargin: 16 + anchors.leftMargin: 24 + anchors.rightMargin: 24 + spacing: 10 - Slide { + Item { + Layout.fillWidth: true + Layout.fillHeight: true - anchors.fill: parent - anchors.verticalCenterOffset: 0 + Rectangle { + id: keret + anchors.horizontalCenter: parent.horizontalCenter + width: Math.min(parent.width, parent.height * 16 / 9) + height: width * 9 / 16 + color: "#141516" + border.width: 1 + border.color: Stilus.keret + clip: true - Image { - id: background2 - source: "images/3.png" - anchors.fill: parent - fillMode: Image.PreserveAspectCrop - smooth: true - mipmap: true - } - } - - Slide { + Repeater { + model: bemutato.kepek - anchors.fill: parent - anchors.verticalCenterOffset: 0 + Image { + anchors.fill: parent + anchors.margins: 1 + visible: index === bemutato.aktualis + source: modelData.forras + sourceSize.width: 1920 + sourceSize.height: 1080 + fillMode: Image.PreserveAspectFit + asynchronous: true + smooth: true + Accessible.role: Accessible.Graphic + Accessible.name: modelData.leiras + } + } + } + } - Image { - id: background3 - source: "images/4.png" - anchors.fill: parent - fillMode: Image.PreserveAspectCrop - smooth: true - mipmap: true - } - } - - Slide { + RowLayout { + Layout.fillWidth: true + spacing: 12 - anchors.fill: parent - anchors.verticalCenterOffset: 0 + Row { + spacing: 6 + Repeater { + model: bemutato.kepek.length + Rectangle { + width: 24 + height: 4 + color: index === bemutato.aktualis ? Stilus.zold : Stilus.keretErosebb + } + } + } - Image { - id: background4 - source: "images/5.png" - anchors.fill: parent - fillMode: Image.PreserveAspectCrop - smooth: true - mipmap: true - } - } - - Slide { + Text { + text: (bemutato.aktualis + 1) + " / " + bemutato.kepek.length + color: Stilus.szovegHalvany + font.family: Stilus.mono + font.pixelSize: 12 + } - anchors.fill: parent - anchors.verticalCenterOffset: 0 + Item { + Layout.fillWidth: true + } - Image { - id: background5 - source: "images/6.png" - anchors.fill: parent - fillMode: Image.PreserveAspectCrop - smooth: true - mipmap: true - } - } - + NyilGomb { + ut: "bal" + Accessible.name: qsTr("Previous slide") + onClicked: bemutato.lapoz(-1) + } - // When this slideshow is loaded as a V1 slideshow, only - // activatedInCalamares is set, which starts the timer (see above). - // - // In V2, also the onActivate() and onLeave() methods are called. - // These example functions log a message (and re-start the slides - // from the first). - function onActivate() { - console.log("QML Component (default slideshow) activated"); - presentation.currentSlide = 0; - } + NyilGomb { + ut: "jobb" + Accessible.name: qsTr("Next slide") + onClicked: bemutato.lapoz(1) + } + } - function onLeave() { - console.log("QML Component (default slideshow) deactivated"); - } + ColumnLayout { + Layout.fillWidth: true + spacing: 8 + + RowLayout { + Layout.fillWidth: true + spacing: 12 + + Text { + Layout.fillWidth: true + text: bemutato.uzenet + elide: Text.ElideRight + color: Stilus.szoveg + font.family: Stilus.font + font.pixelSize: 14 + font.weight: Font.DemiBold + } -}
\ No newline at end of file + Text { + text: Math.round(bemutato.haladas * 100) + "%" + color: Stilus.zold + font.family: Stilus.cim + font.weight: Font.Bold + font.pixelSize: 24 + } + } + + Rectangle { + Layout.fillWidth: true + Layout.preferredHeight: 8 + color: Stilus.keret + Accessible.role: Accessible.ProgressBar + Accessible.name: qsTr("Installation progress") + + Rectangle { + width: parent.width * Math.max(0, Math.min(1, bemutato.haladas)) + height: parent.height + color: Stilus.zold + } + } + } + } +} |