Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove clearSelection(), rename selectAndHighlightCode() #20471

Merged

Conversation

cpirich
Copy link
Contributor

@cpirich cpirich commented Feb 7, 2018

  • clearDropletAceHighlighting() cleared the ACE editor selection in addition to clearing highlights. Presumably, this was originally done because it was the function to "clear" what was done in selectAndHighlightCode(), which used to both select AND highlight the code. Now, that function only does highlighting (and no selection). Renamed that function to highlightCode() to be more clear and removed the ACE editor clearSelection() call from clearDropletAceHighlighting()

Since we recently starting calling this function once per executeInterpreter(), it was preventing students from being able to select code while running

Other places where clearDropletAceHighlighting() is called, that will no longer clear ACE selection:

  • Pressing the Reset button in an app
  • Stepping through code in the debugger and ending up outside of "user code"

In both places, it feels like an improvement to avoid interfering with the ACE editor selection.

Copy link
Contributor

@islemaster islemaster left a comment

Choose a reason for hiding this comment

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

Looks good. Thanks for the detailed description on this change!

@cpirich cpirich merged commit 2d828d5 into staging Feb 7, 2018
@cpirich cpirich deleted the stop_clearing_ace_selection_when_clearing_highlighting branch February 7, 2018 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants