Closed lkcampbell closed 9 years ago
Here's what is happening:
In my extension, AppInit.appReady()
fires off and calls applyPreferences()
, which calls PreferencesManager.get()
functions for all Indent Guide preferences.
The bug is related to timing. If I run the code without pausing in the DevTools debugger, the PreferencesManager.get()
function is ignoring the path-specific preference information and returning the wrong values. If I run the code and step through the PreferencesManager.get()
calls, the calls return the correct path-specific preferences.
This is not an Indent Guides extension bug. It appears to be a problem with the Brackets PreferencesManager
module. If I get time, I will investigate the core bug and post an issue and track it.
The Brackets PreferencesManager
module is complex and would represent a significant amount of time and effort to fix. This issue doesn't happen very often and there are plenty of workarounds available. Closing as invalid since this really is a Brackets core bug.
OS: Mac OSX Mavericks
Brackets Version: Release 1.1 development build 1.1.0-0 (master d9bc65e1d)
Extension Version: 1.3.2
Repro Steps:
"language": { "clojure": { "brackets-indent-guides.guideColor": "red" } }
to brackets.json. Any color value that is not the default color value.Observed Results: Indent guides are the default color value.
Expected Results: Indent guides should be red.
Other Notes: If you navigate to a file written in a different programming language and then navigate back, the guides will turn red.
This isn't specific to the new language scope of preferences, it just happens to be a convenient way to reproduce the issue.
Also happens if you close all open files and then open a clojure file again. Don't even have to reload or restart.