Modules widget: copy only copies the first selected cell

未关闭 适合新手
#1,114 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
88/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
冷清
技术栈
cpp
领域
desktop

调研方向

从 ui/moduleswidget.cpp 中的 DebugModulesWidget::copy() 开始,然后将其与已修复的 DebugMemoryMapWidget::copy() 实现进行比较。移植相关的选择处理,使每个选中的单元格都按视觉顺序复制,并使用制表符分隔列、使用换行符分隔行。

由索引模型根据 Issue 内容生成。

描述

Description

In the Debugger Modules sidebar widget, selecting multiple cells and copying (Ctrl+C / right-click → Copy) only copies the contents of the first selected cell. All other selected cells are ignored.

Cause

DebugModulesWidget::copy() in ui/moduleswidget.cpp only reads sel[0]:

QModelIndexList sel = selectionModel()->selectedIndexes();
if (sel.empty())
    return;

auto sourceIndex = m_filter->mapToSource(sel[0]);   // <-- only the first cell
...
switch (sel[0].column()) { ... }

It should iterate over all selected indexes.

Expected behavior

Copy the contents of every selected cell — grouped by row (tab-separated columns within a row, newline between rows), in visual order — matching typical table-copy behavior.

Notes

The same bug existed in the Memory Map widget (DebugMemoryMapWidget::copy()) and has been fixed there; the same fix should be ported to the Modules widget. See DebugMemoryMapWidget::copy() for the reference implementation.

主要语言
C++
星标
331
派生
33
PR 合并指标
30 天内没有已合并 PR

贡献指南

这个仓库没有索引到贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

Vector35/debugger 的其他 Issue

查看 Vector35/debugger 的全部 Issue

相似的 Issue

更多 C++ Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。