This is a projection, not a development branch. The tree above was constructed from the internal source named below under a manifest that decides which paths may leave, then scanned as a whole tree rather than as a series of patches, and only then published. Public history starts here because the history before it was not admissible, and neither was the tree. What used to stand in this repository included a rescue copy of another machine, a directory of phone handoffs, deployment wired to one house, and a submodule pointing at a forge no stranger can reach. None of that was ever the product. It stays in the private forge, which is allowed to hold the whole working organism, and this is what was deliberately sent out instead. Three mechanisms produced this tree, in decreasing order of trust. A top-level path the manifest does not name never arrives at all, which is the one that catches directories nobody has thought of yet. Named internal files inside admitted roots are dropped. A short, reviewed table replaces deployment defaults that a public build must not carry -- an endpoint aimed at one LAN, a VPN profile belonging to one phone, packaging built from one checkout path. Everything after this commit is an ordinary publication with the same three trailers, so a force push stops being routine and starts meaning that something deliberate happened. The trailers bind the projection to its source without pretending the public SHA is the private one: same lineage, different tree, and the record says so. Source-Sha: 8f27b1e76a8fef560a336aba18e6990713ff1047 Policy-Sha: 6b261d2f3e6e1fb19874846ba4bb1dfe15565d25b8618c1c1afba0419c101d27 Tree-Digest: 18ec3563c5e5ef9a414993a9f6734b251ff9ed3cd56eebdd6cac01e45c6e3067
160 lines
4 KiB
QML
160 lines
4 KiB
QML
import QtQuick
|
|
import QtQuick.Layouts
|
|
import Qt5Compat.GraphicalEffects
|
|
import Quickshell
|
|
import Quickshell.Wayland
|
|
|
|
Scope {
|
|
id: root
|
|
property bool failed;
|
|
property string errorString;
|
|
|
|
// Connect to the Quickshell global to listen for the reload signals.
|
|
Connections {
|
|
target: Quickshell
|
|
|
|
function onReloadCompleted() {
|
|
root.failed = false;
|
|
popupLoader.loading = true;
|
|
}
|
|
|
|
function onReloadFailed(error: string) {
|
|
// Close any existing popup before making a new one.
|
|
popupLoader.active = false;
|
|
|
|
root.failed = true;
|
|
root.errorString = error;
|
|
popupLoader.loading = true;
|
|
}
|
|
}
|
|
|
|
// Keep the popup in a loader because it isn't needed most of the time
|
|
LazyLoader {
|
|
id: popupLoader
|
|
|
|
PanelWindow {
|
|
id: popup
|
|
|
|
exclusiveZone: 0
|
|
anchors.top: true
|
|
margins.top: 0
|
|
|
|
implicitWidth: rect.width + shadow.radius * 2
|
|
implicitHeight: rect.height + shadow.radius * 2
|
|
|
|
WlrLayershell.namespace: "quickshell:reloadPopup"
|
|
|
|
// color blending is a bit odd as detailed in the type reference.
|
|
color: "transparent"
|
|
|
|
Rectangle {
|
|
id: rect
|
|
anchors.centerIn: parent
|
|
color: failed ? "#ffe99195" : "#ffD1E8D5"
|
|
|
|
implicitHeight: layout.implicitHeight + 30
|
|
implicitWidth: layout.implicitWidth + 30
|
|
radius: 12
|
|
|
|
// Fills the whole area of the rectangle, making any clicks go to it,
|
|
// which dismiss the popup.
|
|
MouseArea {
|
|
id: mouseArea
|
|
anchors.fill: parent
|
|
onPressed: {
|
|
popupLoader.active = false
|
|
}
|
|
|
|
// makes the mouse area track mouse hovering, so the hide animation
|
|
// can be paused when hovering.
|
|
hoverEnabled: true
|
|
}
|
|
|
|
ColumnLayout {
|
|
id: layout
|
|
spacing: 10
|
|
anchors {
|
|
top: parent.top
|
|
topMargin: 10
|
|
horizontalCenter: parent.horizontalCenter
|
|
}
|
|
|
|
Text {
|
|
renderType: Text.NativeRendering
|
|
font.family: "Google Sans Flex"
|
|
font.pointSize: 14
|
|
text: root.failed ? "Quickshell: Reload failed" : "Quickshell reloaded"
|
|
color: failed ? "#ff93000A" : "#ff0C1F13"
|
|
}
|
|
|
|
Text {
|
|
renderType: Text.NativeRendering
|
|
font.family: "JetBrains Mono NF"
|
|
font.pointSize: 11
|
|
text: root.errorString
|
|
color: failed ? "#ff93000A" : "#ff0C1F13"
|
|
// When visible is false, it also takes up no space.
|
|
visible: root.errorString != ""
|
|
}
|
|
}
|
|
|
|
// A progress bar on the bottom of the screen, showing how long until the
|
|
// popup is removed.
|
|
Rectangle {
|
|
z: 2
|
|
id: bar
|
|
color: failed ? "#ff93000A" : "#ff0C1F13"
|
|
anchors.bottom: parent.bottom
|
|
anchors.left: parent.left
|
|
anchors.margins: 10
|
|
height: 5
|
|
radius: 9999
|
|
|
|
PropertyAnimation {
|
|
id: anim
|
|
target: bar
|
|
property: "width"
|
|
from: rect.width - bar.anchors.margins * 2
|
|
to: 0
|
|
duration: failed ? 10000 : 1000
|
|
onFinished: popupLoader.active = false
|
|
|
|
// Pause the animation when the mouse is hovering over the popup,
|
|
// so it stays onscreen while reading. This updates reactively
|
|
// when the mouse moves on and off the popup.
|
|
paused: mouseArea.containsMouse
|
|
}
|
|
}
|
|
// Its bg
|
|
Rectangle {
|
|
z: 1
|
|
id: bar_bg
|
|
color: failed ? "#30af1b25" : "#4027643e"
|
|
anchors.bottom: parent.bottom
|
|
anchors.left: parent.left
|
|
anchors.margins: 10
|
|
height: 5
|
|
radius: 9999
|
|
width: rect.width - bar.anchors.margins * 2
|
|
}
|
|
|
|
// We could set `running: true` inside the animation, but the width of the
|
|
// rectangle might not be calculated yet, due to the layout.
|
|
// In the `Component.onCompleted` event handler, all of the component's
|
|
// properties and children have been initialized.
|
|
Component.onCompleted: anim.start()
|
|
}
|
|
|
|
DropShadow {
|
|
id: shadow
|
|
anchors.fill: rect
|
|
horizontalOffset: 0
|
|
verticalOffset: 2
|
|
radius: 6
|
|
samples: radius * 2 + 1 // Ideally should be 2 * radius + 1, see qt docs
|
|
color: "#44000000"
|
|
source: rect
|
|
}
|
|
}
|
|
}
|
|
}
|