https://bugs.kde.org/show_bug.cgi?id=481594

Nicolas Fella <nicolas.fe...@gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Latest Commit|https://invent.kde.org/plas |https://invent.kde.org/plas
                   |ma/plasma-desktop/-/commit/ |ma/plasma-desktop/-/commit/
                   |79070f0646c47554f126b8c3aee |1c9e01b22aefc13d97f066ae3e6
                   |55570d2c61dd0               |0faa9b2e80b52

--- Comment #3 from Nicolas Fella <nicolas.fe...@gmx.de> ---
Git commit 1c9e01b22aefc13d97f066ae3e60faa9b2e80b52 by Nicolas Fella, on behalf
of Harald Sitter.
Committed on 21/02/2024 at 13:28.
Pushed by nicolasfella into branch 'Plasma/6.0'.

kcms/plasmasearch: don't crash on dragging favorties to the end

snap it back to the end instead.

this happens because the pluginselector doodad is a singular list view
with sections. when the user drags an item from the favorites section to
the available section, to reorder an item at the bottom, the new drop
index is inside the model but not inside the m_favoriteMetaDataList.
i.e. its index is model-bound not m_favoriteMetaDataList-bound. we
therefore need to clamp the index at the upper bounds of
m_favoriteMetaDataList manually so as to not work with invalid indexes
(cherry picked from commit 79070f0646c47554f126b8c3aee55570d2c61dd0)

M  +6    -1    kcms/runners/plasmasearch/kcm.cpp
M  +1    -1    kcms/runners/plasmasearch/kcm.h

https://invent.kde.org/plasma/plasma-desktop/-/commit/1c9e01b22aefc13d97f066ae3e60faa9b2e80b52

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to