Eraser malfunction after System Drag & Drop
- Dominant language
- Kotlin
- Stars
- 360
- Forks
- 52
- PR merge metrics
- No merged PRs in 30d
Description
After initiating a system drag-and-drop session via `view.startDragAndDrop` (triggered by a long-press on the `DrawingSurface`), subsequent touch interactions for the **Eraser** tool fail to function.
Although the lines are erased from the underlying canvas, the screen still displays them. The `strokes_data` column for that particular note contains an empty array.
Steps to Reproduce
1. Open a Note in Cahier and draw several lines using any brush.
2. Toggle the Eraser mode off (ensure you are in drawing mode).
3. Long-press on the drawing to initiate the System Drag (the ghost image appears).
4. Release the drag (the ghost image disappears).
5. Toggle Eraser mode ON.
6. Attempt to erase the existing lines.
**Actual Result**: The lines remain visible on the canvas. The eraser appears "dead" or desynced.
**Expected Result**: The eraser should function immediately and accurately after the drag session ends.
https://github.com/user-attachments/assets/1327dc4c-342a-4a30-a81f-6ffeafad6fc1
Contributor guide
Research direction
Start at DrawingSurface and the view.startDragAndDrop call, then trace how touch input and erasing update the canvas after the drag ends. Reproduce the listed steps and verify that existing lines disappear visually as soon as Eraser mode is enabled and used, while the note data remains correct.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, kotlin
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100