1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-08-01 19:18:28 -04:00

launcher: add IPC feature-parity to spotlight-bar and improve list view

transitions

port 1.5
This commit is contained in:
bbedward
2026-07-13 11:25:01 -04:00
parent 31ea83584b
commit 197d17ac4e
5 changed files with 140 additions and 25 deletions
@@ -21,10 +21,10 @@ FocusScope {
readonly property real _rowH: 64
readonly property real _maxResultsH: Math.min(430, (parentModal?.screenHeight ?? 900) * 0.55)
readonly property var _resultRows: _buildRows()
readonly property real _resultsContentH: _resultRows.length > 0 ? _resultRows.length * _rowH : _statusH
readonly property real _resultsContentH: _resultRows.length > 0 ? _resultRows.length * _rowH + resultsList.bottomInset : _statusH
readonly property real _resultsH: _hasQuery ? Math.min(_resultsContentH, _maxResultsH) : 0
readonly property int _fastDuration: 90
readonly property int _resizeDuration: 110
readonly property int _resizeDuration: Theme.expressiveDurations.fast
readonly property bool _blurActive: Theme.blurForegroundLayers || Theme.transparentBlurLayers
readonly property real _searchSurfaceAlpha: {
if (Theme.transparentBlurLayers)
@@ -57,13 +57,18 @@ FocusScope {
const flat = searchController.flatModel || [];
const sections = searchController.sections || [];
const rows = [];
const seen = {};
for (let i = 0; i < flat.length; i++) {
const entry = flat[i];
if (!entry || entry.isHeader || !entry.item)
continue;
const section = sections[entry.sectionIndex] || null;
// Plugin item ids embed result content, so key them by slot position instead
const base = entry.item.pluginId ? (entry.sectionId + ":" + entry.indexInSection) : (entry.item.id || (entry.sectionId + ":" + (entry.item.name || entry.indexInSection)));
const bump = seen[base] || 0;
seen[base] = bump + 1;
rows.push({
"_rowId": entry.item.id || (entry.sectionId + ":" + entry.indexInSection + ":" + i),
"_rowId": bump ? base + "#" + bump : base,
"item": entry.item,
"flatIndex": i,
"sectionTitle": section?.title || "",
@@ -61,6 +61,7 @@ Item {
anchors.bottomMargin: root.bottomInset
clip: true
visible: root.rows.length > 0
add: null
readonly property int rowHeight: 64