Commit Graph

4185 Commits

Author SHA1 Message Date
Corey Johnson
baebc00a7f fix spec bug 2012-12-03 11:07:11 -08:00
Corey Johnson
b4f85621fb remove debug logging 2012-12-03 11:03:00 -08:00
Corey Johnson
5d99824deb autoscroll to results in command panel preview list 2012-12-03 10:23:28 -08:00
Nathan Sobo
5b143d4b93 Add 'autosave' option, which saves when unfocusing or switching tabs 2012-11-30 14:11:27 -07:00
Corey Johnson & Nathan Sobo
d4f44f6554 Give selection view '.selection' class and region divs '.region' class 2012-11-30 12:52:38 -07:00
Corey Johnson & Nathan Sobo
f09fefb780 Selection color is set in themes 2012-11-30 12:44:19 -07:00
Corey Johnson & Nathan Sobo
c7363b3347 Highlight selection w/ animation when autoscroll is true 2012-11-30 12:44:12 -07:00
Corey Johnson & Nathan Sobo
be2b9ee100 Store autoscroll state on Selection and Cursor models 2012-11-30 12:08:41 -07:00
Corey Johnson & Nathan Sobo
b9e847d290 Remove logging 2012-11-30 11:47:36 -07:00
Corey Johnson & Nathan Sobo
ac0e3095ec Only autoscroll selections to center if they are offscreen 2012-11-30 11:40:27 -07:00
Corey Johnson & Nathan Sobo
f9c7c08641 Selected results of a find operation are centered in the viewport 2012-11-29 18:52:34 -07:00
Nathan Sobo
4d63712b52 Calls to EventEmitter#pause and #resume can be nested 2012-11-29 18:51:27 -07:00
Corey Johnson & Nathan Sobo
7eb1f14f05 Don't need to assign retainSelection on the SelectionView anymore 2012-11-29 17:46:58 -07:00
Corey Johnson & Nathan Sobo
702b8047e4 Unwatch all paths after each test 2012-11-29 15:31:05 -08:00
Corey Johnson & Nathan Sobo
290fbfadf8 Change keymap scheme for tool panels.
meta-p        toggle event palette (use this to figure out what we changed)
meta-\        toggle treeview
meta-shift-\  focus current file in treeview
meta-;        command panel
meta-:		  command panel (focus results list)
meta-m		  markdown preview
meta-j		  jump to symbol (outline view)

escape        always closes a tool panel
meta-escape   restore focus to active editor
2012-11-29 15:18:07 -08:00
Corey Johnson & Nathan Sobo
395acaf069 The CommandPanel allows \/ inside of regexes 2012-11-29 14:33:59 -08:00
Nathan Sobo
00832b08bb Allow editor to be focused when it is clicked 2012-11-29 13:57:29 -07:00
Nathan Sobo
4b88a9f5ea Expanded snippets are destroyed when the cursor leaves a tab stop
For this to work, I needed to make the updating of anchors transactional. Now, all anchors are updated and *then* they emit their events. That way when the cursor moves based on the user typing, the tab stop they're in has a chance to expand before we handle the move event. This prevents spurious cancellation of the snippet when typing on a tab stop.
2012-11-29 13:39:00 -07:00
Nathan Sobo
833ccb30ab Pass old and new screen position with Anchor/Cursor move events 2012-11-29 13:39:00 -07:00
Nathan Sobo
91e899456a Rename 'change-screen-position' event to 'moved' on Anchor and Cursor 2012-11-29 13:39:00 -07:00
Corey Johnson
69485724cd Buffer emits a contents-modified event when it's contents differ from disk.
Including when the Buffer's file is removed via another process.
2012-11-29 12:05:05 -08:00
Corey Johnson
ada14a1cba No longer read a File's contents from disk on creation 2012-11-29 11:26:42 -08:00
Nathan Sobo
747d62b032 Fix triggering of change event after file resurrection 2012-11-29 12:01:16 -07:00
Nathan Sobo
98ef054438 💄 2012-11-29 12:01:16 -07:00
Corey Johnson & Nathan Sobo
2cc73b0285 Print exception in error message when an extension fails to load 2012-11-29 12:01:16 -07:00
Corey Johnson
ae00e888fd un-f buffer spec 2012-11-29 10:36:56 -08:00
Corey Johnson
5c4079a2c8 Use NSASCIIStringEncoding instead of NSNonLossyASCIIStringEncoding 2012-11-29 10:36:16 -08:00
Corey Johnson
02c441e937 If $native.read fails to open a file as UTF8, it opens it as ascii
This is a temporary solution to allow Atom to open binary files. The ultimate goal would be to have a hex-editor built into atom.
2012-11-29 10:34:22 -08:00
Corey Johnson
0f0ff425f4 Show stack trace when an extension fails to load 2012-11-29 08:54:08 -08:00
Corey Johnson
04c4c45190 💄 2012-11-29 08:53:39 -08:00
Corey Johnson & Nathan Sobo
e98b4f9a9b Use file contents instead of md5 to determine disk change 2012-11-28 17:16:44 -08:00
Corey Johnson & Nathan Sobo
2f6566d1c5 Make jasmine timeout quicker (the right way) 2012-11-28 17:15:35 -08:00
Corey Johnson & Nathan Sobo
db78d6a7e5 Ensure PathWatcher isn't watching anything at the end of each spec
This replaces the old functionality of ensuring no files or directories have subscriptions in javascript. We allow this now, but we just don't allow leaked watches at the native layer.
2012-11-28 17:16:15 -07:00
Corey Johnson & Nathan Sobo
ac84a8ab0a Destroy buffer to avoid leaking a path watch 2012-11-28 17:13:32 -07:00
Corey Johnson & Nathan Sobo
ce82439420 Make jasmine time out faster on waitsFor blocks 2012-11-28 16:56:30 -07:00
Corey Johnson & Nathan Sobo
d6009df44e Buffers retain path when file is deleted and can be re-saved
Path watching resumes once the file is saved again. This commit allows files to be created for as-yet nonexistent paths. We won't call `$native.watchPath` until we have at least 1 subscription to the file in JS and the file exists on disk.

Also, we moved execution of the path watcher callbacks until after the callbacks data structure is updated in order to avoid confusing behavior in specs.
2012-11-28 16:55:10 -07:00
Corey Johnson & Nathan Sobo
eb0414f4e7 Emit a contents-conflicted` event instead of contents-change-on-disk 2012-11-28 15:21:12 -07:00
Corey Johnson & Nathan Sobo
d5d4751776 Don't set Buffer's file to null when the file is deleted (retain path) 2012-11-28 13:40:37 -07:00
Corey Johnson & Nathan Sobo
d6168b9954 Add EventEmitter#one which adds a one-shot subscription 2012-11-28 13:40:09 -07:00
Corey Johnson & Nathan Sobo
1aa8f26e94 Scrolling does not jerk to a stop when scrolling w/ a trackpad
When scrolling with a trackpad, webkit repeatedly triggers multiple mousewheel events on the original event's target element to simulate the velocity effect we're accustomed to with touchscreen UIs. When scrolling quickly, this clashed with our strategy of removing off-screen lines, because the element was removed before the velocity were done firing.

The solution is to make the overlayer accept mouse events. It lays on top of all the lines, so it is never removed and therefore allows the mousewheel events to run to completion. But, this means we need to transfer mousedown events from the overlayer to the underlying lines.
2012-11-28 12:25:14 -07:00
Nathan Sobo
94220d95a7 When updating lines, build contiguous lines from a single html string
This cuts down on parse time and improves the frame rate when scrolling.
2012-11-27 18:54:26 -07:00
Nathan Sobo
c5a3e81dab Reduce line overdraw to improve scroll performance 2012-11-27 18:19:33 -07:00
Nathan Sobo
d22a199dc6 Simplify handling of 'mousewheel' event 2012-11-27 18:19:17 -07:00
Nathan Sobo
d47a82f585 Handle selection dragging when cursor goes off-screen 2012-11-26 17:21:50 -07:00
Nathan Sobo
bf9a7cc9a1 Fix exception when moving to the end of word when there *is* no word 2012-11-26 15:12:32 -07:00
Nathan Sobo
06e281321b Set z-index on vertical scrollbar so scrollbar can be clicked 2012-11-26 15:06:18 -07:00
Nathan Sobo
cc2e1c1381 Merge pull request #99 from github/async-tokenization
Tokenize asynchronously
2012-11-23 12:05:20 -08:00
Nathan Sobo
a1ae819908 Only tokenize in background if when a buffer is visible in an editor
This will prevent running a bunch of background tokenization when Atom is reloaded. We only perform tokenization to support content that is actually on screen.
2012-11-23 12:41:08 -07:00
Nathan Sobo
f28cedea7d 💄 2012-11-23 12:09:29 -07:00
Nathan Sobo
39863e4ebe 💄 2012-11-23 10:48:00 -07:00