Merge branch 'Ly-sec:main' into main
This commit is contained in:
commit
61df6dde97
16 changed files with 178 additions and 27 deletions
|
|
@ -163,6 +163,7 @@ Scope {
|
||||||
offsetX: -39
|
offsetX: -39
|
||||||
offsetY: 0
|
offsetY: 0
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
|
visible: Settings.settings.showCorners
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -189,6 +190,7 @@ Scope {
|
||||||
offsetX: 39
|
offsetX: 39
|
||||||
offsetY: 0
|
offsetY: 0
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
|
visible: Settings.settings.showCorners
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -214,6 +216,7 @@ Scope {
|
||||||
offsetX: -39
|
offsetX: -39
|
||||||
offsetY: 0
|
offsetY: 0
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
|
visible: Settings.settings.showCorners
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -239,6 +242,7 @@ Scope {
|
||||||
offsetX: 39
|
offsetX: 39
|
||||||
offsetY: 0
|
offsetY: 0
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
|
visible: Settings.settings.showCorners
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -128,7 +128,6 @@ PanelWindow {
|
||||||
text: ToplevelManager?.activeToplevel?.title && ToplevelManager?.activeToplevel?.title.length > 60 ? ToplevelManager?.activeToplevel?.title.substring(0, 60) + "..." : ToplevelManager?.activeToplevel?.title || ""
|
text: ToplevelManager?.activeToplevel?.title && ToplevelManager?.activeToplevel?.title.length > 60 ? ToplevelManager?.activeToplevel?.title.substring(0, 60) + "..." : ToplevelManager?.activeToplevel?.title || ""
|
||||||
font.pixelSize: 12
|
font.pixelSize: 12
|
||||||
color: Theme.textSecondary
|
color: Theme.textSecondary
|
||||||
elide: Text.ElideRight
|
|
||||||
anchors.left: icon.right
|
anchors.left: icon.right
|
||||||
anchors.leftMargin: Settings.settings.showActiveWindowIcon ? 4 : 6
|
anchors.leftMargin: Settings.settings.showActiveWindowIcon ? 4 : 6
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,23 @@ import "../../Helpers/Fuzzysort.js" as Fuzzysort
|
||||||
PanelWithOverlay {
|
PanelWithOverlay {
|
||||||
id: appLauncherPanel
|
id: appLauncherPanel
|
||||||
WlrLayershell.keyboardFocus: WlrKeyboardFocus.OnDemand
|
WlrLayershell.keyboardFocus: WlrKeyboardFocus.OnDemand
|
||||||
|
|
||||||
|
function isPinned(app) {
|
||||||
|
return app && app.execString && Settings.settings.pinnedExecs.indexOf(app.execString) !== -1;
|
||||||
|
}
|
||||||
|
function togglePin(app) {
|
||||||
|
if (!app || !app.execString) return;
|
||||||
|
var arr = Settings.settings.pinnedExecs ? Settings.settings.pinnedExecs.slice() : [];
|
||||||
|
var idx = arr.indexOf(app.execString);
|
||||||
|
if (idx === -1) {
|
||||||
|
arr.push(app.execString);
|
||||||
|
} else {
|
||||||
|
arr.splice(idx, 1);
|
||||||
|
}
|
||||||
|
Settings.settings.pinnedExecs = arr;
|
||||||
|
root.updateFilter();
|
||||||
|
}
|
||||||
|
|
||||||
function showAt() {
|
function showAt() {
|
||||||
appLauncherPanelRect.showAt();
|
appLauncherPanelRect.showAt();
|
||||||
}
|
}
|
||||||
|
|
@ -126,7 +143,22 @@ PanelWithOverlay {
|
||||||
return r.obj;
|
return r.obj;
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
root.filteredApps = results;
|
// Pinning logic: split into pinned and unpinned
|
||||||
|
var pinned = [];
|
||||||
|
var unpinned = [];
|
||||||
|
for (var i = 0; i < results.length; ++i) {
|
||||||
|
var app = results[i];
|
||||||
|
if (app.execString && Settings.settings.pinnedExecs.indexOf(app.execString) !== -1) {
|
||||||
|
pinned.push(app);
|
||||||
|
} else {
|
||||||
|
unpinned.push(app);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Sort pinned alphabetically
|
||||||
|
pinned.sort(function(a, b) {
|
||||||
|
return a.name.toLowerCase().localeCompare(b.name.toLowerCase());
|
||||||
|
});
|
||||||
|
root.filteredApps = pinned.concat(unpinned);
|
||||||
root.selectedIndex = 0;
|
root.selectedIndex = 0;
|
||||||
}
|
}
|
||||||
function selectNext() {
|
function selectNext() {
|
||||||
|
|
@ -143,12 +175,15 @@ PanelWithOverlay {
|
||||||
return;
|
return;
|
||||||
|
|
||||||
var modelData = filteredApps[selectedIndex];
|
var modelData = filteredApps[selectedIndex];
|
||||||
|
const termEmu = Quickshell.env("TERMINAL") || Quickshell.env("TERM_PROGRAM") || "";
|
||||||
|
|
||||||
if (modelData.isCalculator) {
|
if (modelData.isCalculator) {
|
||||||
Qt.callLater(function () {
|
Qt.callLater(function () {
|
||||||
Quickshell.clipboardText = String(modelData.result);
|
Quickshell.clipboardText = String(modelData.result);
|
||||||
Quickshell.execDetached(["notify-send", "Calculator Result", `${modelData.expr} = ${modelData.result} (copied to clipboard)`]);
|
Quickshell.execDetached(["notify-send", "Calculator Result", `${modelData.expr} = ${modelData.result} (copied to clipboard)`]);
|
||||||
});
|
});
|
||||||
|
} else if (modelData.runInTerminal && termEmu){
|
||||||
|
Quickshell.execDetached([termEmu, "-e", modelData.execString.trim()]);
|
||||||
} else if (modelData.execute) {
|
} else if (modelData.execute) {
|
||||||
modelData.execute();
|
modelData.execute();
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -273,10 +308,14 @@ PanelWithOverlay {
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: hovered || isSelected ? Theme.accentPrimary : "transparent"
|
color: (hovered || isSelected)
|
||||||
|
? Theme.accentPrimary
|
||||||
|
: (appLauncherPanel.isPinned(modelData) ? Theme.surfaceVariant : "transparent")
|
||||||
radius: 12
|
radius: 12
|
||||||
border.color: hovered || isSelected ? Theme.accentPrimary : "transparent"
|
border.color: appLauncherPanel.isPinned(modelData)
|
||||||
border.width: hovered || isSelected ? 2 : 0
|
? "transparent"
|
||||||
|
: (hovered || isSelected ? Theme.accentPrimary : "transparent")
|
||||||
|
border.width: appLauncherPanel.isPinned(modelData) ? 0 : (hovered || isSelected ? 2 : 0)
|
||||||
Behavior on color {
|
Behavior on color {
|
||||||
ColorAnimation {
|
ColorAnimation {
|
||||||
duration: 120
|
duration: 120
|
||||||
|
|
@ -328,7 +367,7 @@ PanelWithOverlay {
|
||||||
spacing: 1
|
spacing: 1
|
||||||
Text {
|
Text {
|
||||||
text: modelData.name
|
text: modelData.name
|
||||||
color: hovered || isSelected ? Theme.onAccent : Theme.textPrimary
|
color: (hovered || isSelected) ? Theme.onAccent : (appLauncherPanel.isPinned(modelData) ? Theme.textPrimary : Theme.textPrimary)
|
||||||
font.family: Theme.fontFamily
|
font.family: Theme.fontFamily
|
||||||
font.pixelSize: Theme.fontSizeSmall
|
font.pixelSize: Theme.fontSizeSmall
|
||||||
font.bold: hovered || isSelected
|
font.bold: hovered || isSelected
|
||||||
|
|
@ -338,7 +377,7 @@ PanelWithOverlay {
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: modelData.isCalculator ? (modelData.expr + " = " + modelData.result) : (modelData.comment || modelData.genericName || "No description available")
|
text: modelData.isCalculator ? (modelData.expr + " = " + modelData.result) : (modelData.comment || modelData.genericName || "No description available")
|
||||||
color: hovered || isSelected ? Theme.onAccent : Theme.textSecondary
|
color: (hovered || isSelected) ? Theme.onAccent : (appLauncherPanel.isPinned(modelData) ? Theme.textSecondary : Theme.textSecondary)
|
||||||
font.family: Theme.fontFamily
|
font.family: Theme.fontFamily
|
||||||
font.pixelSize: Theme.fontSizeCaption
|
font.pixelSize: Theme.fontSizeCaption
|
||||||
font.italic: !(modelData.comment || modelData.genericName)
|
font.italic: !(modelData.comment || modelData.genericName)
|
||||||
|
|
@ -355,9 +394,14 @@ PanelWithOverlay {
|
||||||
text: modelData.isCalculator ? "content_copy" : "chevron_right"
|
text: modelData.isCalculator ? "content_copy" : "chevron_right"
|
||||||
font.family: "Material Symbols Outlined"
|
font.family: "Material Symbols Outlined"
|
||||||
font.pixelSize: Theme.fontSizeBody
|
font.pixelSize: Theme.fontSizeBody
|
||||||
color: hovered || isSelected ? Theme.onAccent : Theme.textSecondary
|
color: (hovered || isSelected)
|
||||||
|
? Theme.onAccent
|
||||||
|
: (appLauncherPanel.isPinned(modelData) ? Theme.textPrimary : Theme.textSecondary)
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
|
Layout.rightMargin: 8 // Add margin to separate from star
|
||||||
}
|
}
|
||||||
|
// Add a spacing item between chevron and star
|
||||||
|
Item { width: 8; height: 1 }
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
|
@ -371,7 +415,14 @@ PanelWithOverlay {
|
||||||
id: mouseArea
|
id: mouseArea
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
|
acceptedButtons: Qt.LeftButton | Qt.RightButton
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
// Prevent app launch if click is inside pinArea
|
||||||
|
if (pinArea.containsMouse) return;
|
||||||
|
if (mouse.button === Qt.RightButton) {
|
||||||
|
appLauncherPanel.togglePin(modelData);
|
||||||
|
return;
|
||||||
|
}
|
||||||
ripple.opacity = 0.18;
|
ripple.opacity = 0.18;
|
||||||
rippleNumberAnimation.start();
|
rippleNumberAnimation.start();
|
||||||
root.selectedIndex = index;
|
root.selectedIndex = index;
|
||||||
|
|
@ -398,6 +449,37 @@ PanelWithOverlay {
|
||||||
color: Theme.outline
|
color: Theme.outline
|
||||||
opacity: index === appList.count - 1 ? 0 : 0.10
|
opacity: index === appList.count - 1 ? 0 : 0.10
|
||||||
}
|
}
|
||||||
|
// Pin/Unpin button (move to last child for stacking)
|
||||||
|
Item {
|
||||||
|
id: pinArea
|
||||||
|
width: 28; height: 28
|
||||||
|
z: 100 // Ensure above everything else
|
||||||
|
anchors.right: parent.right
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
MouseArea {
|
||||||
|
anchors.fill: parent
|
||||||
|
preventStealing: true
|
||||||
|
z: 100
|
||||||
|
hoverEnabled: true
|
||||||
|
cursorShape: Qt.PointingHandCursor
|
||||||
|
acceptedButtons: Qt.LeftButton | Qt.RightButton
|
||||||
|
propagateComposedEvents: false
|
||||||
|
onClicked: {
|
||||||
|
appLauncherPanel.togglePin(modelData);
|
||||||
|
event.accepted = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Text {
|
||||||
|
anchors.centerIn: parent
|
||||||
|
text: "star"
|
||||||
|
font.family: "Material Symbols Outlined"
|
||||||
|
font.pixelSize: Theme.fontSizeSmall
|
||||||
|
color: (parent.MouseArea.containsMouse || hovered || isSelected)
|
||||||
|
? Theme.onAccent
|
||||||
|
: (appLauncherPanel.isPinned(modelData) ? Theme.textPrimary : Theme.textDisabled)
|
||||||
|
verticalAlignment: Text.AlignVCenter
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -51,8 +51,8 @@ PopupWindow {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: bg
|
id: bg
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: Theme.backgroundElevated || "#222"
|
color: Theme.surfaceVariant || "#222"
|
||||||
border.color: Theme.border || "#444"
|
border.color: Theme.outline || "#444"
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: 12
|
radius: 12
|
||||||
z: 0
|
z: 0
|
||||||
|
|
@ -84,7 +84,7 @@ PopupWindow {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: parent.width - 20
|
width: parent.width - 20
|
||||||
height: 1
|
height: 1
|
||||||
color: Qt.darker(Theme.backgroundElevated || "#222", 1.4)
|
color: Qt.darker(Theme.surfaceVariant || "#222", 1.4)
|
||||||
visible: modelData?.isSeparator ?? false
|
visible: modelData?.isSeparator ?? false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -168,11 +168,17 @@ Item {
|
||||||
color: {
|
color: {
|
||||||
if (model.isFocused)
|
if (model.isFocused)
|
||||||
return Theme.accentPrimary;
|
return Theme.accentPrimary;
|
||||||
if (model.isActive)
|
|
||||||
return Theme.accentPrimary.lighter(130);
|
|
||||||
if (model.isUrgent)
|
if (model.isUrgent)
|
||||||
return Theme.error;
|
return Theme.error;
|
||||||
return Qt.lighter(Theme.surfaceVariant, 1.6);
|
if (model.isActive)
|
||||||
|
return Theme.accentSecondary;
|
||||||
|
if (model.isOccupied)
|
||||||
|
return Qt.darker(Theme.accentSecondary, 1.5);
|
||||||
|
|
||||||
|
if (model.isUrgent)
|
||||||
|
return Theme.error;
|
||||||
|
|
||||||
|
return Theme.surfaceVariant.lighter(1.5);
|
||||||
}
|
}
|
||||||
scale: model.isFocused ? 1.0 : 0.9
|
scale: model.isFocused ? 1.0 : 0.9
|
||||||
z: 0
|
z: 0
|
||||||
|
|
@ -182,7 +188,7 @@ Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
cursorShape: Qt.PointingHandCursor
|
cursorShape: Qt.PointingHandCursor
|
||||||
onClicked: {
|
onClicked: {
|
||||||
WorkspaceManager.switchToWorkspace(model.idx);
|
WorkspaceManager.switchToWorkspace(model.id);
|
||||||
}
|
}
|
||||||
z: 20
|
z: 20
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
|
|
|
||||||
|
|
@ -67,9 +67,9 @@ Scope {
|
||||||
process.index = 0;
|
process.index = 0;
|
||||||
}
|
}
|
||||||
for (let i = 0; i < data.length; i += 1) {
|
for (let i = 0; i < data.length; i += 1) {
|
||||||
newValues[i + process.index] = Math.min(data.charCodeAt(i), 128) / 128;
|
newValues[process.index] = Math.min(data.charCodeAt(i), 128) / 128;
|
||||||
|
process.index = (process.index+1) % count;
|
||||||
}
|
}
|
||||||
process.index += data.length;
|
|
||||||
values = newValues;
|
values = newValues;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Window 2.15
|
import QtQuick.Window 2.15
|
||||||
import qs.Settings
|
import qs.Settings
|
||||||
|
|
||||||
|
|
@ -57,8 +57,8 @@ Window {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: 6
|
radius: 6
|
||||||
color: "#222"
|
color: Theme.backgroundTertiary || "#222"
|
||||||
border.color: Theme.backgroundTertiary || "#444"
|
border.color: Theme.outline || "#444"
|
||||||
border.width: 1
|
border.width: 1
|
||||||
opacity: 0.97
|
opacity: 0.97
|
||||||
z: 1
|
z: 1
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
function fetchCoordinates(city, callback, errorCallback) {
|
function fetchCoordinates(city, callback, errorCallback) {
|
||||||
var geoUrl = "https://geocoding-api.open-meteo.com/v1/search?name=" + encodeURIComponent(city) + "&count=1&language=en&format=json";
|
var geoUrl = "https://geocoding-api.open-meteo.com/v1/search?name=" + encodeURIComponent(city) + "&language=en&format=json";
|
||||||
var xhr = new XMLHttpRequest();
|
var xhr = new XMLHttpRequest();
|
||||||
xhr.onreadystatechange = function() {
|
xhr.onreadystatechange = function() {
|
||||||
if (xhr.readyState === XMLHttpRequest.DONE) {
|
if (xhr.readyState === XMLHttpRequest.DONE) {
|
||||||
|
|
|
||||||
|
|
@ -183,7 +183,7 @@ You will need to install a few things to get everything working:
|
||||||
- `swww` to add fancy wallpaper animations (optional)
|
- `swww` to add fancy wallpaper animations (optional)
|
||||||
- `wallust` to theme the setup based on wallpaper (optional)
|
- `wallust` to theme the setup based on wallpaper (optional)
|
||||||
|
|
||||||
## zigstat and zigbrightnesss is bundled - source can be found [here](https://git.pika-os.com/wm-packages/pikabar/src/t).
|
## zigstat and zigbrightnesss is bundled - source can be found [here](https://git.pika-os.com/wm-packages/pikabar/src/branch/main/src)
|
||||||
|
|
||||||
## Known issues
|
## Known issues
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -49,10 +49,10 @@ Singleton {
|
||||||
isFocused: ws.is_focused === true,
|
isFocused: ws.is_focused === true,
|
||||||
isActive: ws.is_active === true,
|
isActive: ws.is_active === true,
|
||||||
isUrgent: ws.is_urgent === true,
|
isUrgent: ws.is_urgent === true,
|
||||||
activeWindowId: ws.active_window_id
|
isOccupied: ws.active_window_id ? true : false
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
workspacesList.sort((a, b) => {
|
workspacesList.sort((a, b) => {
|
||||||
if (a.output !== b.output) {
|
if (a.output !== b.output) {
|
||||||
return a.output.localeCompare(b.output);
|
return a.output.localeCompare(b.output);
|
||||||
|
|
|
||||||
|
|
@ -124,7 +124,8 @@ Singleton {
|
||||||
output: ws.output || "",
|
output: ws.output || "",
|
||||||
isFocused: ws.isFocused === true,
|
isFocused: ws.isFocused === true,
|
||||||
isActive: ws.isActive === true,
|
isActive: ws.isActive === true,
|
||||||
isUrgent: ws.isUrgent === true
|
isUrgent: ws.isUrgent === true,
|
||||||
|
isOccupied: ws.isOccupied === true,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -45,6 +45,7 @@ Singleton {
|
||||||
property string videoPath: "~/Videos/"
|
property string videoPath: "~/Videos/"
|
||||||
property bool showActiveWindowIcon: false
|
property bool showActiveWindowIcon: false
|
||||||
property bool showSystemInfoInBar: false
|
property bool showSystemInfoInBar: false
|
||||||
|
property bool showCorners: true
|
||||||
property bool showMediaInBar: false
|
property bool showMediaInBar: false
|
||||||
property bool useSWWW: false
|
property bool useSWWW: false
|
||||||
property bool randomWallpaper: false
|
property bool randomWallpaper: false
|
||||||
|
|
|
||||||
|
|
@ -112,4 +112,3 @@ Singleton {
|
||||||
property int fontSizeSmall: Math.round(14 * fontSizeMultiplier) // Small text like clock, labels
|
property int fontSizeSmall: Math.round(14 * fontSizeMultiplier) // Small text like clock, labels
|
||||||
property int fontSizeCaption: Math.round(12 * fontSizeMultiplier) // Captions and fine print
|
property int fontSizeCaption: Math.round(12 * fontSizeMultiplier) // Captions and fine print
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -39,6 +39,7 @@ PanelWindow {
|
||||||
appName: notification.appName || "Notification",
|
appName: notification.appName || "Notification",
|
||||||
summary: notification.summary || "",
|
summary: notification.summary || "",
|
||||||
body: notification.body || "",
|
body: notification.body || "",
|
||||||
|
urgency: notification.urgency || 0,
|
||||||
rawNotification: notification,
|
rawNotification: notification,
|
||||||
appeared: false,
|
appeared: false,
|
||||||
dismissed: false
|
dismissed: false
|
||||||
|
|
@ -91,6 +92,8 @@ PanelWindow {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
color: Theme.backgroundPrimary
|
color: Theme.backgroundPrimary
|
||||||
radius: 20
|
radius: 20
|
||||||
|
border.color: model.urgency == 2 ? Theme.warning : Theme.outline
|
||||||
|
border.width: 1
|
||||||
|
|
||||||
property bool appeared: model.appeared
|
property bool appeared: model.appeared
|
||||||
property bool dismissed: model.dismissed
|
property bool dismissed: model.dismissed
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ import qs.Settings
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: profileSettingsCard
|
id: profileSettingsCard
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: 540
|
Layout.preferredHeight: 580
|
||||||
color: Theme.surface
|
color: Theme.surface
|
||||||
radius: 18
|
radius: 18
|
||||||
border.color: "transparent"
|
border.color: "transparent"
|
||||||
|
|
@ -252,6 +252,61 @@ Rectangle {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Show Corners In Bar Setting
|
||||||
|
RowLayout {
|
||||||
|
spacing: 8
|
||||||
|
Layout.fillWidth: true
|
||||||
|
Layout.topMargin: 8
|
||||||
|
|
||||||
|
Text {
|
||||||
|
text: "Show Corners"
|
||||||
|
font.family: Theme.fontFamily
|
||||||
|
font.pixelSize: 13
|
||||||
|
font.bold: true
|
||||||
|
color: Theme.textPrimary
|
||||||
|
Layout.alignment: Qt.AlignVCenter
|
||||||
|
}
|
||||||
|
|
||||||
|
Item {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
}
|
||||||
|
|
||||||
|
// Custom Material 3 Switch
|
||||||
|
Rectangle {
|
||||||
|
id: customSwitch4
|
||||||
|
width: 52
|
||||||
|
height: 32
|
||||||
|
radius: 16
|
||||||
|
color: Settings.settings.showCorners ? Theme.accentPrimary : Theme.surfaceVariant
|
||||||
|
border.color: Settings.settings.showCorners ? Theme.accentPrimary : Theme.outline
|
||||||
|
border.width: 2
|
||||||
|
|
||||||
|
Rectangle {
|
||||||
|
id: thumb4
|
||||||
|
width: 28
|
||||||
|
height: 28
|
||||||
|
radius: 14
|
||||||
|
color: Theme.surface
|
||||||
|
border.color: Theme.outline
|
||||||
|
border.width: 1
|
||||||
|
y: 2
|
||||||
|
x: Settings.settings.showCorners ? customSwitch4.width - width - 2 : 2
|
||||||
|
|
||||||
|
Behavior on x {
|
||||||
|
NumberAnimation { duration: 200; easing.type: Easing.OutCubic }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
MouseArea {
|
||||||
|
anchors.fill: parent
|
||||||
|
cursorShape: Qt.PointingHandCursor
|
||||||
|
onClicked: {
|
||||||
|
Settings.settings.showCorners = !Settings.settings.showCorners
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Show Media In Bar Setting
|
// Show Media In Bar Setting
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
|
|
||||||
|
|
@ -71,6 +71,7 @@ Scope {
|
||||||
appName: notification.appName || "Notification",
|
appName: notification.appName || "Notification",
|
||||||
summary: notification.summary || "",
|
summary: notification.summary || "",
|
||||||
body: notification.body || "",
|
body: notification.body || "",
|
||||||
|
urgency: notification.urgency,
|
||||||
timestamp: Date.now()
|
timestamp: Date.now()
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue