Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Jul 29, 2019. It is now read-only.

Conversation

@wimrijnders
Copy link

This wraps it up for the settings changes.

  • Grouped all settings code and moved to bottom of file.
  • Consolidated code for settings in constructor and setOptions()
  • Added label autoByDefault for better displaying intent for settings.
  • Removed superfluous comments

I would still like to move this code to a module of its own.
It's distinct from the rest and easy to separate. I hope you can agree with this.

@mojoaxel
Copy link
Member

I would still like to move this code to a module of its own.
It's distinct from the rest and easy to separate. I hope you can agree with this.

Of course!
more mular = more good ;-)

@mojoaxel
Copy link
Member

mojoaxel commented Oct 20, 2016

@wimrijnders Just to make it clear: All existing options and settings are still the same and function like documented? Than I see no reason not to finalise your big code cleanup...

@wimrijnders
Copy link
Author

Thanks. Settings module on my TODO.

Yes, confirm: all existing options and settings are identical to previous. For the (external) user there is no difference. This was an internal restructuring.

mular - It's a typo, but I think we need to give it a definition and make it a standard term.
(sorry couldn't resist)

@wimrijnders
Copy link
Author

I see this PR is still open; I'll add the changes for creating the Settings module here, OK? I hope that was your intention as well.

@yotamberk
Copy link
Member

Sounds good

@wimrijnders
Copy link
Author

wimrijnders commented Oct 21, 2016

OK done with Settings module. No more changes for this PR, you can merge if you approve.

Moving the settings code to a module was a straightforward translation, with the following exceptions:

  • I really like having DEFAULTS on the top of Graph3d.js. So Settings.js just stores a reference to it.
  • Partly because of previous, I added some extra parameter checking. Scan for isEmpty() in Settings.js.
  • I had to make a choice where to put enum STYLE; I put it in Settings.js because this makes easier handling.
  • Also moved the style names to Settings.js; reworked it to a hash, renamed _getStyleNumber() to getStyleNumberByName().

@yotamberk yotamberk merged commit 5030993 into visjs:develop Oct 21, 2016
@wimrijnders wimrijnders deleted the PR14 branch October 21, 2016 13:58
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants