File tree Expand file tree Collapse file tree 3 files changed +8
-9
lines changed Expand file tree Collapse file tree 3 files changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -137,10 +137,7 @@ class MinimapElement {
137137 * @access private
138138 */
139139 this . textOpacity = undefined
140- /**
141- * @access private
142- */
143- this . displayCodeHighlights = undefined
140+
144141 /**
145142 * @access private
146143 */
@@ -262,7 +259,7 @@ class MinimapElement {
262259 } ) ,
263260
264261 atom . config . observe ( 'minimap.displayCodeHighlights' , ( displayCodeHighlights ) => {
265- this . displayCodeHighlights = displayCodeHighlights
262+ this . CanvasDrawer . displayCodeHighlights = displayCodeHighlights
266263
267264 if ( this . attached ) { this . requestForcedUpdate ( ) }
268265 } ) ,
@@ -889,7 +886,7 @@ class MinimapElement {
889886 * highlights or not
890887 */
891888 setDisplayCodeHighlights ( displayCodeHighlights ) {
892- this . displayCodeHighlights = displayCodeHighlights
889+ this . CanvasDrawer . displayCodeHighlights = displayCodeHighlights
893890 if ( this . attached ) { this . requestForcedUpdate ( ) }
894891 }
895892
Original file line number Diff line number Diff line change @@ -21,6 +21,8 @@ export default class CanvasDrawer {
2121 constructor ( ) {
2222 // set in setModel of minimapElement
2323 this . minimap = undefined
24+ // set by minimapElement
25+ this . displayCodeHighlights = undefined
2426 }
2527 /**
2628 * Initializes the canvas elements needed to perform the `Minimap` rendering.
Original file line number Diff line number Diff line change @@ -1827,7 +1827,7 @@ describe('MinimapElement', () => {
18271827 } )
18281828
18291829 it ( 'toggles the code highlights on the minimap element' , ( ) => {
1830- expect ( minimapElement . displayCodeHighlights ) . toBeTruthy ( )
1830+ expect ( minimapElement . CanvasDrawer . displayCodeHighlights ) . toBeTruthy ( )
18311831 } )
18321832
18331833 it ( 'requests an update' , ( ) => {
@@ -1996,14 +1996,14 @@ describe('MinimapElement', () => {
19961996 describe ( 'on the code highlight item' , ( ) => {
19971997 let [ initial ] = [ ]
19981998 beforeEach ( ( ) => {
1999- initial = minimapElement . displayCodeHighlights
1999+ initial = minimapElement . CanvasDrawer . displayCodeHighlights
20002000 atom . commands . dispatch ( quickSettingsElement , 'core:move-down' )
20012001 atom . commands . dispatch ( quickSettingsElement , 'core:move-down' )
20022002 atom . commands . dispatch ( quickSettingsElement , 'core:confirm' )
20032003 } )
20042004
20052005 it ( 'toggles the code highlights on the minimap element' , ( ) => {
2006- expect ( minimapElement . displayCodeHighlights ) . toEqual ( ! initial )
2006+ expect ( minimapElement . CanvasDrawer . displayCodeHighlights ) . toEqual ( ! initial )
20072007 } )
20082008 } )
20092009
You can’t perform that action at this time.
0 commit comments