Merge pull request #74 from derrickoswald/dev

- axes size made settable
- big cleanup/refactoring/bugfix of application core (project(s) related)
 * moved the project , project file and project files folder classes to a "dot" access syntax instead of get/set
 * renamed projectFiles class to folder
 * removed "ext" (extension) attribute in project file class, extension is now part of the name
 * cleaned up project attributes, added and isCompileAdvised attribute to files and project: this is used to signal that there were changes which would require a re-compile
 * dirty flag use cleaned up and clarified : only concerns when a project/file should be saved
 * cleaned up all methods for classes above
 * started adding "underscores" in front of internal/private methods
 * overwrote project, and file save methods for more coherent results, and to avoid saving certain attributes
 * added persistedAttributeNames to file and project classes to be able to specify which attributes should be persisted (others are discarded)

- various "compile modes" switching is now handled correctly
 * compile on save now works
 * switching between all modes works as expected aswell
 * fixed a few event binding issues in project manager, cleaned up code, centralized event binding to a single method

- continued cleanup of file tabs and tree views
 * added modelbinder use here and there to cut down on the event spaghetti amount
 * some weird issues with re-rendering of treeview not taking place on model change needs to be investigated
renamed project/file 'dirty' attribute to isSaveAdvised
- added a few keyboard shortcuts (experimental)
 * not yet settable via the settings menu
 * bindings for new, load,save and compile project
- added main menu notifications for project load, save and compile
- trying to fix various storage related issues, and to have a "clean" api for various storage types
  * cleaned up dropbox & browser connectors
  * cleaned up storage related elements in various project classes
  * right now , its either or for dropbox & browser : the "special" methods for saving file's raw data to dropbox works for save & load, but is at l
least partially incompatible with the standard bkbone sync methods, localstorage works, but requires a different save procedure in the Project class
  * model destruction was not done correctly (files were removed from the collection not destroyed), that is now corrected in the file tree view
  * experimented with delayed destroy in the dropbox connector, so model deletion only happends on "save": works but is hack-ish
- renamed all connectors to "stores" (as connectors does not make much sens given that they STORE data)
- deleted old app main file (app_old.coffee)
- added modelbinding to stl & amf exporter views
 * now the export button is automagically disabled based on the projects compile status
 * a bit of template & code cleanup
- more refinement and experimentation with project managment views/ functionality
 * added correct retrieval and display of project's files list (now used by projectBrowseView2 to display the selected project's list of files)
 * added better visuals for the above
 * tried yet again to have a cleaner projectBrowserView (v3) : still not good: tried to use collection binders (see src/app/modules/core/utils/DataBoundViews.coffee)
 * added main menu entry for project browser (no implementation)

- finally fixed the code editor's resize issues:
 * passing better params to jqueryUi layout
 * and via hacks (javascript resize event callback setting sizes)

- improved filesTreeView
 * better visuals through use of standard bootstrap css
 * removed some custom css : should be avoided when possible until I switch to "LESS"
 * added backbone.pickysitter to enable single view selection (and therefore auto deselect of all other views)
 * minor bugfix and slight cosmetic improvement to the file renaming system (error class gets removed after a timeout, in case of already existing file name)

- deleted some old unused files
- further fixes and enhancements to storage related things
 * added "delete" context menu to projectbrowserview
 * hence some updates to the contextmenu (not quite there yet)
 * added single select system for stores in the view
 * cleaned up event binding a bit
 * added preliminary support for renaming projects
 * slowly moving away from the backbone's "sync" method for localstorage, as it is highly unpractical in our case, and requires a ton of hack (but could be me)
- decided to switch to mostly custom persistence so now both backbone and browser storage set
a dataStore on the project, which is then used for custom persistence
 * added more gracefull handling of model destruction (in case a dataStore is set for the model)
 * modified the browser storage according to the above
 * added a destroyFile method to stores
 * added "auto cleanup" to browser storage : old files not present in the project anymore are deleted from storage
 * this fixes #48 and closes #57
- turns out, there were plenty more bugs in both the browser and dropbox store:
 * fixed project deletion  and creation in browser store
 * fixed "save" event not fired by dropbox store for files
 * fixed browserview issue, where the div ids for project names were not unique resulting in dual (visual only) removal in all store views
 * minor cleanups and fixes in project , main menu etc
- updated three.js to latest (r57), some (failed) attempts at fixing custom orbit controls pan
- oh yeah ! finally got the CustomOrbitControls pan working correctly !
 * fixes #46
- fixed a number of tests, updating and adding specs
 * partially fixed pre processor, exporters and project tests, related project implementation change : see below
 * fixed preprocessor include process for in-project includes (reqRes issue)
 * added file/project fetch prefix for reqres, to allow different stores to respond to their specific requests
 * started modifying stores accordingly, almost there !

- moved all compiling related code to a new "compiler" class
 * modified project and project manager accordingly
 * compiler instance is passed to / instanciated in project
 * re added "compile" method to project for convienence (project is a FACADE for functionality after all)
- further enhancement and refinements to the "include" system
 * modified the "load project" methods of store to return a deferred
 * partially migrated the preprocessor to handle this correctly
 * added a small "trick" to handle "nested includes" (includes associated with a file included in another project) : when fetching file data, all relative (local)
includes are replaced with absolute ones
 * most of the test are now a-ok BUT since the defferred/async nature of file content returned to the preprocessor is not handled correctly, this might fail
 * some minor cleanup here and there
- started work on a storeBase class, to clean up the api of both store, and refactor common elements
- refactoring the preprocessor to handle the deferred approach correctly
 * things are thus broken for now, but getting there
 * instead of using the string.replace(pattern, callback) method, the process is now seperated into finding matches -> processing
and doing the "include" replacement in the deferred's callback methods
- oh yeah ! new preprocessor works correctly with defereds !
 * finished new implementation, needs a bit of cleanup
 * all tests pass (those that should)
 * modified compiler accordingly, did a few live tests: a-ok !
- fixed a BAD bug (bad deferred list used) in the preprocessor, cleaned it up
- added a "clear_flags" method to the project class, to reset the projects isCompileAdvised etc flags to a default state (was needed for project load with bad "dirtiness" indication)
- some cleanup in compiler, and the different stores
- compiler now returns a deferred for optional chaining and easier testing,
 * modified project tests accordingly, now all passing
 * cleanup in pre processor, project, and compiler

- modified bom generation (in compiler) so it generated end data based on the actual instances in the assembly, and not just counting instances
 * fixes #75
 * also fixed accidentally removed project:loaded event binding in coffeescad.app.coffee

-small fixes to deferreds in backbone.dropbox (now using deferred.reject() instead of fail() -> ouch, was completely wrong)
 * small amout of other related cleanups
- cleanup and fixes to the bom exporter:
 * now , it works again, yay !