Commit Graph
24 Commits
Author SHA1 Message Date
Erik Tierney 9416e75828 Add tests for jscodehints in an html file.
Also fix some bugs with jump-to-def and function type hints uncovered by the tests.
2013-05-02 16:28:40 -04:00
dloverin 3a22861211 small changes for code review 2013-04-26 16:57:15 -04:00
dloverin 52d98980f0 Close hints when the cursor moves to a new hinting context 2013-04-26 09:57:08 -04:00
Erik Tierney 10f8896d46 cleanup based on codereview comments:
Update jsdoc
use ExtensionUtils.getModulePath instead of manually slicing up path
use FileUtils.readAsText instead of DocumentManager when we only need the text on disk
Call CollectionUtils.hasProperty instead of Object.prototype.hasOwnProperty...
Add comment explaining logic around finding location of called function for function type hinting
remove unnecessary calls to setCursorPos
remove stale comments in unittests
pull out hint invalidation check into a function and remove check for query.length === 0, not necessary anymore
2013-04-18 16:38:40 -04:00
dloverin f6a073ca3d When typing, only automatically show hints for the "." character and JS identifier characters. 2013-04-17 17:29:48 -04:00
Erik Tierney c5052f8e33 Add a couple of unit tests for jump to definition
Only tests in file, inter file needs more work - have to figure out how to make CommandManager work from the unittester.
2013-04-16 18:49:09 -04:00
Erik Tierney ebc6b647c6 Add some more unit tests
covers require support, jsdoc, function types
2013-04-16 11:51:41 -04:00
Erik Tierney d96d73d895 cleanup jslint warnings 2013-04-15 09:43:37 -04:00
dloverin 3eee0bef6f use .value instead of .label to reduce confusion 2013-04-13 11:01:46 -04:00
dloverin ab0b3728a1 Get hint value from 'label' property instead of 'value' property 2013-04-13 09:50:54 -04:00
Erik Tierney e46d260a09 Get all unit tests passing
Fix a caching problem where old hints were getting used.
Update selection tests to search for the index to insert instead of hardcoding the index so the tests are less fragile.
2013-04-12 15:14:26 -04:00
Erik Tierney 5e11b5abf1 Updates to expected results. 2013-04-12 13:30:11 -04:00
Erik Tierney ee2dd1d518 Fix for issue when multiple requests were made
Were creating a new Promise for each request, but only resolving the last one.  Now check to see if we already have a promise for a particular request, and return the already existing one if there is one.
2013-04-11 16:31:36 -04:00
Erik Tierney 8131900e9b Some unit test cleanup 2013-04-11 15:49:07 -04:00
Peter Flynn 821b7b2e19 Move status bar code out of EditorManager into a new module. Keeps
EditorManager tightly focused on maintaining the set of Editors and gives
the status bar code room to grow for future UI additions.

This removes EditorManager._init() and the manual calls to it from unit
tests, which seem unnecessary. EditorStatusBar._init() is still called on
htmlReady - just not manually called by any unit tests.

Also, change the status bar code to use active editor more consistently
(used to use focused editor sometimes).
2013-03-06 20:09:50 -08:00
Peter Flynn 5a026ec9ff Update JS code hints (including unit tests) to work with new language and
Editor APIs.
2013-02-26 15:45:23 -08:00
Joel Brandt 1f1d074180 more doc fixups 2013-02-26 09:53:54 -08:00
Joel Brandt bc8d9d8e2a more fixes to jsdocs 2013-02-26 06:16:30 -08:00
Ian Wehrman c8b53c7153 type capitalization typos and additional JSDoc annotations 2013-02-25 17:53:00 -08:00
Ian Wehrman 3d66c59b7e Typos and clarifications 2013-02-24 12:51:01 -08:00
Ian Wehrman c0e75bcc7e Add remaining JSDoc annotations 2013-02-24 12:45:58 -08:00
Ian Wehrman 27b7dce115 Address initial comments and suggestions from code review by @rlim. 2013-02-21 11:01:14 -08:00
Ian Wehrman 9c371fc518 Add built-in global objects, and a TODO to also add built-in global properties and associations. 2013-02-15 14:03:27 -08:00
Ian Wehrman 786cd23bce Add the JS code hinter as a default extension. 2013-02-14 15:59:12 -08:00