cleanup unneeded logging
Format (JS/TS) / format (pull_request) Failing after 6s
Lint (JS/TS) / lint (pull_request) Failing after 11s
Lint (Python) / lint (pull_request) Failing after 19s
Lint (Rust) / lint (pull_request) Failing after 1m34s

This commit is contained in:
2026-05-19 16:15:39 +02:00
parent 9c6a1ce1a4
commit 62ec1b9f33
6 changed files with 20 additions and 50 deletions
-1
View File
@@ -32,7 +32,6 @@ CustomMouseArea {
if (root.visibilities.isDrawing && (event.buttons & Qt.LeftButton)) {
root.drawing.points.push(Qt.point(x, y));
console.log(root.drawing.points);
root.drawing.requestPaint();
}
-1
View File
@@ -346,7 +346,6 @@ Singleton {
stdout: StdioCollector {
onStreamFinished: {
console.log("this is running");
if (root.gpuType === "GENERIC") {
const percs = text.trim().split("\n");
const sum = percs.reduce((acc, d) => acc + parseInt(d, 10), 0);
+20 -44
View File
@@ -7,23 +7,30 @@ import QtQuick
Singleton {
id: root
// The list of users that can log in graphically
// Each user object has: username, uid, home, shell, gecos (full name), face (avatar path)
readonly property string defaultUserFile: "/etc/zshell-greeter/default-user"
property int selectedIndex: 0
readonly property var selectedUser: selectedIndex >= 0 && selectedIndex < users.length ? users[selectedIndex] : null
readonly property string selectedUsername: selectedUser ? selectedUser.username : ""
property var users: []
// The currently selected user index
property int selectedIndex: 0
function saveDefaultUser(): void {
if (selectedUser) {
defaultUserStorage.setText(selectedUser.username);
}
}
// The currently selected user object (or null if none)
readonly property var selectedUser: selectedIndex >= 0 && selectedIndex < users.length ? users[selectedIndex] : null
function selectNext(): void {
if (users.length === 0)
return;
selectedIndex = (selectedIndex + 1) % users.length;
}
// Convenience property for the selected username
readonly property string selectedUsername: selectedUser ? selectedUser.username : ""
function selectPrevious(): void {
if (users.length === 0)
return;
selectedIndex = (selectedIndex - 1 + users.length) % users.length;
}
// Path to store the default user preference
readonly property string defaultUserFile: "/etc/zshell-greeter/default-user"
// Select a user by username
function selectUser(username: string): bool {
for (let i = 0; i < users.length; i++) {
if (users[i].username === username) {
@@ -34,28 +41,6 @@ Singleton {
return false;
}
// Select the next user in the list (wraps around)
function selectNext(): void {
if (users.length === 0)
return;
selectedIndex = (selectedIndex + 1) % users.length;
}
// Select the previous user in the list (wraps around)
function selectPrevious(): void {
if (users.length === 0)
return;
selectedIndex = (selectedIndex - 1 + users.length) % users.length;
}
// Save the current user as the default for next login
function saveDefaultUser(): void {
if (selectedUser) {
defaultUserStorage.setText(selectedUser.username);
}
}
// Process to fetch the list of graphical users
Process {
id: userLister
@@ -67,13 +52,10 @@ Singleton {
try {
root.users = JSON.parse(text);
// If we have users and no selection yet, try to select the default user
if (root.users.length > 0) {
// Try to load the default user
if (defaultUserStorage.loaded) {
const defaultUsername = defaultUserStorage.text().trim();
if (defaultUsername && !root.selectUser(defaultUsername)) {
// Default user not found, select first user
root.selectedIndex = 0;
}
} else {
@@ -87,15 +69,14 @@ Singleton {
}
}
// FileView for persisting the default user
FileView {
id: defaultUserStorage
path: root.defaultUserFile
preload: true
onLoadFailed: {}
onLoaded: {
// If users are already loaded, try to select the default user
if (root.users.length > 0) {
const defaultUsername = text().trim();
if (defaultUsername) {
@@ -103,10 +84,5 @@ Singleton {
}
}
}
onLoadFailed: {
// File doesn't exist yet, that's fine - we'll create it on first save
console.log("No default user file found, will use first user");
}
}
}
-1
View File
@@ -13,7 +13,6 @@ Searcher {
function launch(entry: DesktopEntry): void {
appDb.incrementFrequency(entry.id);
console.log(root.command);
if (entry.runInTerminal)
Quickshell.execDetached({
-2
View File
@@ -51,8 +51,6 @@ Item {
implicitHeight: searchContainer.implicitHeight
implicitWidth: 200
Component.onCompleted: console.log(root.height)
Shortcut {
sequence: "/"
-1
View File
@@ -19,7 +19,6 @@ Scope {
if (!root.launcherInterrupted && !root.hasFullscreen) {
const visibilities = Visibilities.getForActive();
visibilities.launcher = !visibilities.launcher;
console.log(root.launcherInterrupted);
}
root.launcherInterrupted = false;
}