fixed volume popup closing when changing a device + made notifications and volume fonts bolder
This commit is contained in:
@@ -143,6 +143,7 @@ ModuleChip {
|
||||
text: toastRoot.urgencyIcon(toastRoot.urgency)
|
||||
color: toastRoot.urgencyColor(toastRoot.urgency)
|
||||
font.pixelSize: 12
|
||||
font.bold: true
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
@@ -162,6 +163,7 @@ ModuleChip {
|
||||
text: toastRoot.timeStr
|
||||
color: toastRoot.t.notifToastDim
|
||||
font.pixelSize: 11
|
||||
font.bold: true
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
@@ -177,6 +179,7 @@ ModuleChip {
|
||||
text: "✕"
|
||||
color: closeHover.hovered ? toastRoot.t.notifToastText : toastRoot.t.notifToastDim
|
||||
font.pixelSize: 10
|
||||
font.bold: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
HoverHandler { id: closeHover; cursorShape: Qt.PointingHandCursor }
|
||||
@@ -200,6 +203,7 @@ ModuleChip {
|
||||
text: toastRoot.body
|
||||
color: toastRoot.t.notifToastDim
|
||||
font.pixelSize: 12
|
||||
font.bold: true
|
||||
Layout.fillWidth: true
|
||||
wrapMode: Text.WordWrap
|
||||
maximumLineCount: 3
|
||||
@@ -251,8 +255,8 @@ ModuleChip {
|
||||
|
||||
signal dismissed(int itemIndex)
|
||||
|
||||
height: histItemContent.implicitHeight + 24
|
||||
radius: 12
|
||||
height: histItemContent.implicitHeight + 16
|
||||
radius: 10
|
||||
clip: true
|
||||
color: histItemHover.hovered ? histRoot.t.notifHistoryHover : "transparent"
|
||||
Behavior on color { ColorAnimation { duration: 150; easing.type: Easing.OutCubic } }
|
||||
@@ -271,48 +275,59 @@ ModuleChip {
|
||||
|
||||
Rectangle {
|
||||
width: 3
|
||||
height: Math.max(12, histRoot.height - 24)
|
||||
height: Math.max(10, histRoot.height - 16)
|
||||
radius: 1.5
|
||||
anchors { left: parent.left; leftMargin: 10; verticalCenter: parent.verticalCenter }
|
||||
anchors { left: parent.left; leftMargin: 8; verticalCenter: parent.verticalCenter }
|
||||
color: histRoot.urgencyColor(histRoot.urgency)
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors { right: parent.right; top: parent.top; margins: 8 }
|
||||
width: 22; height: 22; radius: 11
|
||||
anchors { right: parent.right; top: parent.top; margins: 6 }
|
||||
width: 18; height: 18; radius: 9
|
||||
color: histCloseHover.hovered ? histRoot.t.notifHistoryHover : "transparent"
|
||||
opacity: histItemHover.hovered ? 1 : 0
|
||||
Behavior on opacity { NumberAnimation { duration: 150 } }
|
||||
Behavior on color { ColorAnimation { duration: 150 } }
|
||||
|
||||
Text { anchors.centerIn: parent; text: "✕"; color: histRoot.t.notifToastText; font.pixelSize: 10; renderType: Text.NativeRendering }
|
||||
Text { anchors.centerIn: parent; text: "✕"; color: histRoot.t.notifToastText; font.pixelSize: 10; font.bold: true; renderType: Text.NativeRendering }
|
||||
HoverHandler { id: histCloseHover; cursorShape: Qt.PointingHandCursor }
|
||||
TapHandler { onTapped: dismissAnim.start() }
|
||||
}
|
||||
|
||||
Text {
|
||||
anchors { right: parent.right; rightMargin: 6; top: parent.top; topMargin: 8 }
|
||||
text: histRoot.timeStr
|
||||
color: histRoot.t.notifToastDim
|
||||
font.pixelSize: 10
|
||||
font.bold: true
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
renderType: Text.NativeRendering
|
||||
opacity: histItemHover.hovered ? 0 : 1
|
||||
Behavior on opacity { NumberAnimation { duration: 150 } }
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: histItemContent
|
||||
anchors { left: parent.left; right: parent.right; top: parent.top; leftMargin: 24; rightMargin: 36; topMargin: 12 }
|
||||
spacing: 4
|
||||
anchors { left: parent.left; right: parent.right; top: parent.top; leftMargin: 20; rightMargin: 40; topMargin: 8 }
|
||||
spacing: 2
|
||||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true; spacing: 5
|
||||
Text { text: histRoot.urgencyIcon(histRoot.urgency); color: histRoot.urgencyColor(histRoot.urgency); font.pixelSize: 11; Layout.alignment: Qt.AlignVCenter; renderType: Text.NativeRendering }
|
||||
Text { text: histRoot.urgencyIcon(histRoot.urgency); color: histRoot.urgencyColor(histRoot.urgency); font.pixelSize: 10; font.bold: true; Layout.alignment: Qt.AlignVCenter; renderType: Text.NativeRendering }
|
||||
Text {
|
||||
text: histRoot.appName; color: histRoot.t.notifToastAppName; font.pixelSize: 12; font.bold: true
|
||||
text: histRoot.appName; color: histRoot.t.notifToastAppName; font.pixelSize: 11; font.bold: true
|
||||
font.capitalization: Font.AllUppercase; font.letterSpacing: 0.4; Layout.fillWidth: true; elide: Text.ElideRight; verticalAlignment: Text.AlignVCenter
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
Text { text: histRoot.timeStr; color: histRoot.t.notifToastDim; font.pixelSize: 11; verticalAlignment: Text.AlignVCenter; renderType: Text.NativeRendering }
|
||||
}
|
||||
|
||||
Text {
|
||||
text: histRoot.summary; color: histRoot.t.notifToastText; font.pixelSize: 13; font.bold: true
|
||||
text: histRoot.summary; color: histRoot.t.notifToastText; font.pixelSize: 12; font.bold: true
|
||||
Layout.fillWidth: true; elide: Text.ElideRight; textFormat: Text.PlainText; visible: histRoot.summary !== ""
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
Text {
|
||||
text: histRoot.body; color: histRoot.t.notifToastDim; font.pixelSize: 12; Layout.fillWidth: true
|
||||
text: histRoot.body; color: histRoot.t.notifToastDim; font.pixelSize: 11; font.bold: true; Layout.fillWidth: true
|
||||
wrapMode: Text.WordWrap; maximumLineCount: 2; elide: Text.ElideRight; textFormat: Text.PlainText; visible: histRoot.body !== ""; lineHeight: 1.2
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
@@ -344,6 +359,7 @@ ModuleChip {
|
||||
? t.notifDnd
|
||||
: (root.unreadCount > 0 ? t.notifIconActive : t.notifIcon)
|
||||
font.pixelSize: Cfg.Config.notifIconSize
|
||||
font.bold: true
|
||||
Behavior on color { ColorAnimation { duration: 150 } }
|
||||
|
||||
rotation: 0
|
||||
@@ -586,7 +602,7 @@ ModuleChip {
|
||||
anchors.topMargin: 20; anchors.leftMargin: 20; anchors.rightMargin: 20
|
||||
spacing: 10
|
||||
|
||||
Text { text: ""; color: t.notifToastAppName; font.pixelSize: 18; Layout.alignment: Qt.AlignVCenter; renderType: Text.NativeRendering }
|
||||
Text { text: ""; color: t.notifToastAppName; font.pixelSize: 18; font.bold: true; Layout.alignment: Qt.AlignVCenter; renderType: Text.NativeRendering }
|
||||
Text {
|
||||
text: "Notifications"; color: t.notifToastAppName; font.pixelSize: 15; font.bold: true
|
||||
Layout.fillWidth: true; Layout.alignment: Qt.AlignVCenter; renderType: Text.NativeRendering
|
||||
@@ -613,6 +629,7 @@ ModuleChip {
|
||||
text: ""
|
||||
color: root.doNotDisturb ? t.notifDnd : t.notifToastDim
|
||||
font.pixelSize: 12
|
||||
font.bold: true
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
Behavior on color { ColorAnimation { duration: 150 } }
|
||||
renderType: Text.NativeRendering
|
||||
@@ -621,7 +638,7 @@ ModuleChip {
|
||||
text: root.doNotDisturb ? "On" : "Off"
|
||||
color: root.doNotDisturb ? t.notifDnd : t.notifToastDim
|
||||
font.pixelSize: 11
|
||||
font.bold: root.doNotDisturb
|
||||
font.bold: true
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
Behavior on color { ColorAnimation { duration: 150 } }
|
||||
renderType: Text.NativeRendering
|
||||
@@ -641,7 +658,7 @@ ModuleChip {
|
||||
color: clearHover.hovered ? t.notifHistoryHover : "transparent"
|
||||
Behavior on color { ColorAnimation { duration: 150 } }
|
||||
|
||||
Text { id: clearText; anchors.centerIn: parent; text: "Clear all"; color: t.notifToastDim; font.pixelSize: 11; renderType: Text.NativeRendering }
|
||||
Text { id: clearText; anchors.centerIn: parent; text: "Clear all"; color: t.notifToastDim; font.pixelSize: 11; font.bold: true; renderType: Text.NativeRendering }
|
||||
HoverHandler { id: clearHover; cursorShape: Qt.PointingHandCursor }
|
||||
TapHandler { onTapped: clearAllAnim.start() }
|
||||
}
|
||||
@@ -693,8 +710,8 @@ ModuleChip {
|
||||
width: histCol.width - 16; height: 90; visible: notifHistory.count === 0
|
||||
ColumnLayout {
|
||||
anchors.centerIn: parent; spacing: 8
|
||||
Text { text: ""; color: t.notifHistoryEmpty; font.pixelSize: 30; Layout.alignment: Qt.AlignHCenter; renderType: Text.NativeRendering }
|
||||
Text { text: "No notifications"; color: t.notifHistoryEmpty; font.pixelSize: 12; Layout.alignment: Qt.AlignHCenter; renderType: Text.NativeRendering }
|
||||
Text { text: ""; color: t.notifHistoryEmpty; font.pixelSize: 30; font.bold: true; Layout.alignment: Qt.AlignHCenter; renderType: Text.NativeRendering }
|
||||
Text { text: "No notifications"; color: t.notifHistoryEmpty; font.pixelSize: 12; font.bold: true; Layout.alignment: Qt.AlignHCenter; renderType: Text.NativeRendering }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -153,7 +153,9 @@ ModuleChip {
|
||||
text: root.speakerGlyph(root.outputMuted, root.outputVolume)
|
||||
color: root.outputMuted ? root.t.volIconMuted : root.t.volIcon
|
||||
font.pixelSize: Cfg.Config.volumeIconSize
|
||||
font.bold: true
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
}
|
||||
|
||||
@@ -190,7 +192,6 @@ ModuleChip {
|
||||
color: root.t.volPopupBg
|
||||
border.color: root.t.volPopupBorder
|
||||
border.width: Cfg.Config.popupBorderWidth
|
||||
layer.enabled: true
|
||||
|
||||
MouseArea { anchors.fill: parent; propagateComposedEvents: false }
|
||||
|
||||
@@ -254,8 +255,10 @@ ModuleChip {
|
||||
text: "Volume Limits"
|
||||
color: root.t.textDim
|
||||
font.pixelSize: 10
|
||||
font.bold: true
|
||||
font.capitalization: Font.AllUppercase
|
||||
Layout.fillWidth: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
LimitRow {
|
||||
Layout.fillWidth: true
|
||||
@@ -324,6 +327,8 @@ ModuleChip {
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.preferredWidth: Cfg.Config.volumeIconSize + 4
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
renderType: Text.NativeRendering
|
||||
font.bold: true
|
||||
}
|
||||
Text {
|
||||
text: vs.label
|
||||
@@ -331,6 +336,7 @@ ModuleChip {
|
||||
font.pixelSize: 13
|
||||
font.bold: true
|
||||
Layout.fillWidth: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
Text {
|
||||
text: vs.muted ? "muted" : vs.volume + "%"
|
||||
@@ -339,6 +345,7 @@ ModuleChip {
|
||||
font.bold: !vs.muted
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
Layout.preferredWidth: 44
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
@@ -351,6 +358,8 @@ ModuleChip {
|
||||
text: vs.muted ? "" : ""
|
||||
color: vs.muted ? vs.accentColor : vs.dimColor
|
||||
font.pixelSize: 11
|
||||
font.bold: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
HoverHandler { id: muteHover; cursorShape: Qt.PointingHandCursor }
|
||||
TapHandler { onTapped: vs.muteToggled() }
|
||||
@@ -403,13 +412,15 @@ ModuleChip {
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
spacing: 6
|
||||
Text { text: ""; color: vs.dimColor; font.pixelSize: 11 }
|
||||
Text { text: ""; color: vs.dimColor; font.pixelSize: 11; font.bold: true; renderType: Text.NativeRendering }
|
||||
Text {
|
||||
text: vs.deviceName
|
||||
color: vs.textColor
|
||||
font.pixelSize: 11
|
||||
font.bold: true
|
||||
elide: Text.ElideRight
|
||||
Layout.fillWidth: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
@@ -422,6 +433,8 @@ ModuleChip {
|
||||
text: vs.pickerOpen ? "" : ""
|
||||
color: vs.pickerOpen ? vs.accentColor : vs.dimColor
|
||||
font.pixelSize: 10
|
||||
font.bold: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
HoverHandler { id: chevHover; cursorShape: Qt.PointingHandCursor }
|
||||
TapHandler { onTapped: vs.pickerOpen = !vs.pickerOpen }
|
||||
@@ -470,8 +483,9 @@ ModuleChip {
|
||||
Text {
|
||||
text: modelData.description || modelData.nickName || modelData.name
|
||||
color: isActive ? vs.accentColor : vs.textColor
|
||||
font.pixelSize: 11; font.bold: isActive
|
||||
font.pixelSize: 11; font.bold: true
|
||||
elide: Text.ElideRight; Layout.fillWidth: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
}
|
||||
HoverHandler { id: rowHover; cursorShape: Qt.PointingHandCursor }
|
||||
@@ -499,12 +513,14 @@ ModuleChip {
|
||||
signal decrement()
|
||||
signal increment()
|
||||
|
||||
Text { text: lr.icon; color: lr.iconColor; font.pixelSize: 13 }
|
||||
Text { text: lr.icon; color: lr.iconColor; font.pixelSize: 13; font.bold: true; renderType: Text.NativeRendering }
|
||||
Text {
|
||||
text: lr.labelText
|
||||
color: lr.textColor
|
||||
font.pixelSize: 11
|
||||
font.bold: true
|
||||
Layout.fillWidth: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
@@ -516,6 +532,8 @@ ModuleChip {
|
||||
anchors.centerIn: parent; text: "−"
|
||||
color: lr.value <= lr.minValue ? lr.dimColor : lr.textColor
|
||||
font.pixelSize: 14
|
||||
font.bold: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
HoverHandler { id: decHover; cursorShape: Qt.PointingHandCursor }
|
||||
TapHandler { onTapped: { if (lr.value > lr.minValue) lr.decrement() } }
|
||||
@@ -526,6 +544,7 @@ ModuleChip {
|
||||
font.pixelSize: 12; font.bold: true
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
Layout.preferredWidth: 44
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
@@ -537,6 +556,8 @@ ModuleChip {
|
||||
anchors.centerIn: parent; text: "+"
|
||||
color: lr.value >= lr.maxValue ? lr.dimColor : lr.textColor
|
||||
font.pixelSize: 14
|
||||
font.bold: true
|
||||
renderType: Text.NativeRendering
|
||||
}
|
||||
HoverHandler { id: incHover; cursorShape: Qt.PointingHandCursor }
|
||||
TapHandler { onTapped: { if (lr.value < lr.maxValue) lr.increment() } }
|
||||
|
||||
Reference in New Issue
Block a user