Created attachment 146351 [details] Plasma desktop containment - disappearing icons and binding loop in FolderItemDelegate for verticalAlignment SUMMARY When moving a grid [at least 2x2 worth] of items like files and folders on a desktop containment configured (by default) as a folder view, all items except one would disappear upon mouse key release, and there would be lots of binding loops warning printed to a terminal. Either this is something recent, or I just never had so many files on a desktop at once that I'd need to move them in a grid. I suspected «positioner: Fix deferred move with multiple items»[1] patch at first, but Severin von Wnuck @medusalix tried Plasma 5.24 without that patch and confirmed the bug still exists. STEPS TO REPRODUCE 1. Put at least 4 files on your desktop. 2. Arrange them in a grid with at least 2 rows and 2 columns. 3. Select all of them. 4. Drag to a new place on a desktop. OBSERVED RESULT One item remains, others disappear. Binding loop warnings are printed to a terminal. EXPECTED RESULT It should normally drag and drop. SOFTWARE/OS VERSIONS Operating System: Arch Linux KDE Plasma Version: 5.24.80 KDE Frameworks Version: 5.91.0 Qt Version: 5.15.2 Kernel Version: 5.16.5-arch1-1 (64-bit) Graphics Platform: X11 Processors: 8 × Intel® Core™ i7-6700HQ CPU @ 2.60GHz Memory: 15.6 GiB of RAM Graphics Processor: NVIDIA GeForce GTX 970M/PCIe/SSE2 plasma-desktop: 963b4ee7a1c56ee68a2d5bf0557862d497fea974 plasma-workspace: daed0461ebafe1c70821f6852394b058078d3315 plasma-framework: 850051e0a0b577e6c22b67e2ba04a7c8c8ed25cb ADDITIONAL INFORMATION [1]: https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/836
Actually, might happen with a single row of multiple items as well.
It seems like it has something to do with the Sticky Notes widget. If I drop icons near that widget they disappear entirely.
> It seems like it has something to do with the Sticky Notes widget. If I drop icons near that widget they disappear entirely. Or even just dragging around and over it but dropping in entirely different place far away from it
I think I've found the culprit: https://invent.kde.org/plasma/kdeplasma-addons/-/blob/2c39c2051d9c7fc9e2e5c28c1d0ed44ea582ccd6/applets/notes/package/contents/ui/main.qml#L354 If you remove that line the text area won't get focused anymore if you drag items over the notes widget. But it resolves the disappearing icons issue.
> I think I've found the culprit: > If you remove that line the text area won't get focused anymore if you drag items over the notes widget. But it resolves the disappearing icons issue. Great job! Now, I don't have much experience with drag & drop in QML, and I wonder why that manual focusing is even needed? AFAICT all other apps handle this by just drawing a cursor without focusing the text field when you drag something over it; and if you release inside, it would insert the content, and then depending on a GUI framework some apps will even set focus to this text field.
Indeed, seems unnecessary. Wanna test out removing to make sure nothing breaks, and then submit a merge request for it?
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kdeplasma-addons/-/merge_requests/113
Git commit cd39585efa070291964db3e2d45319bc1ee34e06 by Severin von Wnuck. Committed on 07/02/2022 at 20:12. Pushed by ngraham into branch 'master'. [applets/notes] Fix drag-and-drop focus stealing The sticky note widget focuses the text area when dragging desktop icons over the widget. This can cause the desktop icons to disappear once they are dropped on the desktop. M +0 -1 applets/notes/package/contents/ui/main.qml https://invent.kde.org/plasma/kdeplasma-addons/commit/cd39585efa070291964db3e2d45319bc1ee34e06
Git commit e6fc3c0015dc18ea0c901480c1fe5db86b0a2396 by Nate Graham, on behalf of Severin von Wnuck. Committed on 07/02/2022 at 21:50. Pushed by ngraham into branch 'Plasma/5.24'. [applets/notes] Fix drag-and-drop focus stealing The sticky note widget focuses the text area when dragging desktop icons over the widget. This can cause the desktop icons to disappear once they are dropped on the desktop. (cherry picked from commit cd39585efa070291964db3e2d45319bc1ee34e06) M +0 -1 applets/notes/package/contents/ui/main.qml https://invent.kde.org/plasma/kdeplasma-addons/commit/e6fc3c0015dc18ea0c901480c1fe5db86b0a2396