Skip to content

Conversation

@paulkaplan
Copy link
Contributor

@paulkaplan paulkaplan commented Dec 4, 2018

Resolves

What Github issue does this resolve (please include link)?

Resolves scratchfoundation/scratch-gui#1850

Proposed Changes

Describe what this Pull Request does

Add a RUNTIME_DISPOSED event that the pen extension listens for and clears the pen layer when it occurs.

No attempt is made in this PR to unload the extension blocks or anything like that.

Repro that now works:

  1. Add pen extension
  2. Move the cat around and stamp a bunch of times
  3. "File -> New"
  4. See that the pen layer is cleared.

Copy link
Contributor

@kchadha kchadha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Failing test, but after that LG.

Co-Authored-By: paulkaplan <pkaplan@media.mit.edu>
@paulkaplan
Copy link
Contributor Author

Thanks for that! I was being too hasty! Included your suggestion.

Copy link
Contributor

@kchadha kchadha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kchadha kchadha assigned paulkaplan and unassigned kchadha Dec 5, 2018
@paulkaplan paulkaplan merged commit ff33917 into scratchfoundation:develop Dec 5, 2018
@paulkaplan paulkaplan deleted the clear-pen-on-dispose branch December 5, 2018 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pen layer not cleared if you switch projects

2 participants