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

toggle for auto-updating from code editor #651

Closed
wants to merge 49 commits into from
Closed

Conversation

bjkomer
Copy link
Contributor

@bjkomer bjkomer commented Feb 5, 2016

Adding the option to disable automatic synchronization of the model and the code in the editor.

Which shortcut keys to use is still up in the air, currently using Ctrl-Shift-1 to toggle auto-updating, and Ctrl-1 to trigger an update. The toggle can also be set in the config, and the trigger with a tool bar button (which also doubles as an indicator of whether or not the code differs from the model).
Addresses #644 and also provides a way around #444 #550

Allowed Shift-Enter to run the model from the editor window (also works in the other windows). Addresses #639

@tcstewar
Copy link
Collaborator

tcstewar commented Feb 6, 2016

Nifty! And I like how clean the implementation is.... :)

I'm still not sure what the right hot-key should be for updating the netgraph. Any suggestions?

I'm also not sure about the icon, but I'm having trouble finding a better one...

@tcstewar
Copy link
Collaborator

tcstewar commented Feb 6, 2016

Argh; this needs to get updated for the persistent storage stuff that got merged already.

@tcstewar
Copy link
Collaborator

tcstewar commented Feb 6, 2016

I'm also not sure about the icon, but I'm having trouble finding a better one...

Maybe glyphicon-circle-arrow-left ?

@bjkomer bjkomer added this to the 0.2 release milestone Feb 6, 2016
@tcstewar
Copy link
Collaborator

tcstewar commented Feb 6, 2016

Ah, we have a wiki page for more icons!

https://github.com/nengo/nengo_gui/wiki/Icon-Libraries

rsimmons1 and others added 24 commits February 9, 2016 12:08
The bulk of the logic is in `static/config.js`.
So far we only persist the 4 configuration options accessible through
the gear icon in the top toolbar, but we can add more things easily.

A few other related changes:
- Changed several attributes to properties with a getter/setter in
  netgraph.js so that you don't have to remember to fire off a
  `set_` or `update_` function when changing them.
- Cleaned up the configuration modal code.
- Added a test to ensure that changing things persists in local storage.

Pair programmed with: Dan Rasmussen <drasmuss@uwaterloo.ca>
This persists three additional items related to the code editor:

1. Whether it is shown or hidden.
2. The width of the code editor.
3. The font size used in the editor.

Additionally, we refactored the code significantly, removing several
functions that were only called once, and making several functions
into a property's getter/setter.

Also removed a very strange line of code that set the global
Nengo.ace in the Nengo.Ace constructor.

Pair programmed with: Dan Rasmussen <drasmuss@uwaterloo.ca>
@tcstewar
Copy link
Collaborator

tcstewar commented Feb 9, 2016

Grr, looks like I screwed up the rebase on this one. :( I'm going to make a new branch with just the actual content of this PR. Sorry about complicating things!

@tcstewar
Copy link
Collaborator

tcstewar commented Feb 9, 2016

I've made a new PR for this based on current master: #676

@tcstewar
Copy link
Collaborator

tcstewar commented Feb 9, 2016

This got merged as #676 (same content, but with a cleaner history than this one, due to a mess I made)

@tcstewar tcstewar closed this Feb 9, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

6 participants