mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2025-12-05 21:15:38 -05:00
Readjustment of the audio display name for better fit (#874)
This commit is contained in:
@@ -355,10 +355,10 @@ Rectangle {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: {
|
text: {
|
||||||
const mediaName = modelData && modelData.properties ? (modelData.properties["media.name"] || "") : "";
|
const modelDataMediaName = modelData && modelData.properties ? (modelData.properties["media.name"] || "") : "";
|
||||||
const max = 30;
|
const mediaName = AudioService.displayName(modelData) + ": " + modelDataMediaName;
|
||||||
const truncated = mediaName.length > max ? mediaName.substring(0, max) + "..." : mediaName;
|
const max = 35;
|
||||||
return AudioService.displayName(modelData) + (truncated ? ": " + truncated : "");
|
return mediaName.length > max ? mediaName.substring(0, max) + "..." : mediaName;
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.fontSizeMedium
|
font.pixelSize: Theme.fontSizeMedium
|
||||||
color: Theme.surfaceText
|
color: Theme.surfaceText
|
||||||
|
|||||||
Reference in New Issue
Block a user