┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/views/dolphinview.cpp
diff options
context:
space:
mode:
authorJin Liu <[email protected]>2024-10-11 16:08:31 +0800
committerJin Liu <[email protected]>2024-10-12 21:17:38 +0800
commit829e0eb912a5681d5c6fddfd461165ae9f5cb093 (patch)
treebbada6410f648fc95b99a9404781c302b792362a /src/views/dolphinview.cpp
parentc5238c9946805c8aef69f4b52689ba5a700c913e (diff)
KFileItemModel: fix `setData` in the renaming usage
The `setData` function is used by inline renaming to update the `text` role (i.e. file name) in the model before actually do the renaming. However, the current implementation only updates `text` and url in KFileItem in this case, leaving the `url` role and the `m_items` cache untouched. This makes the cache incoherent, so `index()` won't find the renamed item. It also makes the `url` role incoherent with the `text` role. This also fixes the problem mentioned in bug #481561 where when inline renaming fails, it still shows the new name. (Because `m_model->index` fails to find the new name and rename it back on job failure.) BUG: 481561
Diffstat (limited to 'src/views/dolphinview.cpp')
0 files changed, 0 insertions, 0 deletions