Commit Graph

159 Commits

Author SHA1 Message Date
Jess Lin
ecdf324e62 [Gutter] TextEditorPresenter: rename updateGutterState -> updateLineNumberGutterState 2015-04-22 07:28:57 -07:00
Jess Lin
fccc9ebee4 [Gutter] Rename current references to 'Gutter' -> 'LineNumberGutter' 2015-04-22 07:28:56 -07:00
Ben Ogle
48c05210fa Remove specs from text-editor-component 2015-04-01 17:41:00 -07:00
Ben Ogle
bed09cf0ef Presenter positions overlays when the overlay doesn’t have a size
Fix presenter specs
2015-04-01 17:41:00 -07:00
Ben Ogle
77139104fd Remove getOverlayDimensions
No longer needed
2015-04-01 17:41:00 -07:00
Ben Ogle
b0794bbb68 Move the overlay calculation into the presenter. 2015-04-01 17:40:59 -07:00
Ben Ogle
c62f06af9d Cache the overlay dimensions in the presenter 2015-04-01 17:40:59 -07:00
Ben Ogle
6b5a74e3b6 Update specs for overlay rendering 2015-04-01 17:40:59 -07:00
Kevin Sawicki
d9a5aff919 Add explicit return after for loop 2015-03-19 11:48:40 -07:00
Antonio Scandurra
0940c9216f Update also @startRow and @endRow on getState 2015-03-09 09:11:39 +01:00
Nathan Sobo
1e1eae4758 🎨 2015-02-28 10:57:32 -07:00
Antonio Scandurra
d05fe8a7d8 🎨 Remove repetitive batching code 2015-02-28 12:34:58 +01:00
Antonio Scandurra
ac01d3ec45 Remove newline 2015-02-28 10:10:42 +01:00
Antonio Scandurra
436322fc41 Call it onDidUpdateState 2015-02-28 09:36:56 +01:00
Antonio Scandurra
0dca5a5fcd Encapsulate state update inside TextEditorPresenter#getState 2015-02-28 09:25:53 +01:00
Antonio Scandurra
290acb356c 🎨 Remove unnecessary newlines 2015-02-27 21:01:46 +01:00
Antonio Scandurra
fbec9e31c4 Let's call it needsUpdate 😉 2015-02-27 20:54:00 +01:00
Antonio Scandurra
bcc99c163f Rename applyChanges to update 2015-02-27 20:42:04 +01:00
Antonio Scandurra
a4fe18abd5 🎨 Extract helpers and make code simpler 2015-02-27 19:53:54 +01:00
Antonio Scandurra
bf16287b16 🎨 Avoid entering/exiting from the outside 2015-02-27 16:59:59 +01:00
Antonio Scandurra
2f00d3e361 Batch on @requestUpdate 2015-02-27 15:10:17 +01:00
Antonio Scandurra
0948f1abdf Merge branch 'master' into batch-updates 2015-02-27 12:46:25 +01:00
Antonio Scandurra
af65849880 Move batching management down into presentation layer 2015-02-27 12:17:34 +01:00
Nathan Sobo
6a9abd1f66 🐎 Don’t blink cursors when editor isn’t focused
Signed-off-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2015-02-26 15:23:11 -07:00
Nathan Sobo
cd310dbe58 Rename ‘blinkCursorsOff’ to ‘cursorsVisible’ in presenter state 2015-02-26 15:21:47 -07:00
Antonio Scandurra
50f2aded3a Better batching 2015-02-26 11:26:48 +01:00
Antonio Scandurra
cbfbf84990 🐎 Introduce batching, and update UI accordingly 2015-02-25 17:40:39 +01:00
Antonio Scandurra
8f2df60eab 🎨 Refactor batchMode 2015-02-25 17:06:35 +01:00
Antonio Scandurra
ce8a5a210c Detect batch cursor move 2015-02-25 17:06:35 +01:00
Antonio Scandurra
b2bed7cea8 Detect batch selections 2015-02-25 17:06:34 +01:00
Antonio Scandurra
cc9ed043c7 🐎 Update needed cursors only 2015-02-24 16:39:39 +01:00
Nathan Sobo
2e8c5855d4 Don’t attempt to preserve mouseWheelScreenRow if it’s deleted
Fixes #5527
2015-02-23 10:51:16 -08:00
Nathan Sobo
e244aae7c0 Cache ::showIndentGuide config setting 2015-02-19 17:14:56 -07:00
Nathan Sobo
5ecefe7213 Update scoped config values in presenter when grammar changes 2015-02-19 17:14:56 -07:00
Nathan Sobo
156569f19e Add TextEditorPresenter::state.gutter.visible 2015-02-19 17:14:55 -07:00
Nathan Sobo
4654bad543 Add .focused to presenter state
Signed-off-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2015-02-19 17:14:55 -07:00
Nathan Sobo
8e27d8215a Store hidden input data in TextEditorPresenter::state 2015-02-19 17:14:54 -07:00
Nathan Sobo
c06e100fae Make LinesComponent a normal object instead of a React component
Also, remove ability to disable hardware acceleration since there’s
no longer a need for it and it complicated this conversion.
2015-02-19 17:14:53 -07:00
Nathan Sobo
55a70da3cf Hide scrollbars on mini editors
Fixes #5548
2015-02-13 19:37:27 -07:00
Max Brunsfeld
9517410ef4 Incrementally initialize presenter in random mutation spec
Fix resulting failures

Signed-off-by: Nathan Sobo <nathan@github.com>
2015-02-13 18:05:05 -08:00
Nathan Sobo
6a36bdda25 Replace ::hasRequiredMeasurements() with specific criteria in presenter
Now each update method requires a list of specific variables to be
defined before running.
2015-02-12 19:48:06 -07:00
Nathan Sobo
5b6990f14c Don’t update state in presenter unless prerequisites are defined
Signed-off-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2015-02-12 19:39:11 -07:00
Nathan Sobo
e739444800 Add an assertion when line is null in presenter
Refs #5527
2015-02-12 13:23:42 -07:00
Nathan Sobo
b3d03d032a 🐎 Read TextEditor::cursors directly to avoid allocation 2015-02-12 11:34:45 -07:00
Nathan Sobo
205d1df7b4 Precompute ::startRow and ::endRow in presenter 2015-02-12 11:34:45 -07:00
Nathan Sobo
cc80378b29 Precompute ::scrollTop in presenter 2015-02-12 09:36:44 -07:00
Nathan Sobo
54fcaa6132 Precompute ::scrollHeight and cache ::scrollPastEnd config value 2015-02-11 23:01:08 -07:00
Nathan Sobo
05554d03e4 Precompute ::scrollWidth 2015-02-11 22:53:38 -07:00
Nathan Sobo
fc603aaa0d Precompute ::clientHeight and ::clientWidth 2015-02-11 22:42:32 -07:00
Nathan Sobo
cf958ffeac Don’t cascade computed values unless upstream values change 2015-02-11 22:34:42 -07:00