Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CLOSED] Active line highlight doesn't disappear in unfocused editor #3057

Open
core-ai-bot opened this issue Aug 29, 2021 · 2 comments
Open

Comments

@core-ai-bot
Copy link
Member

Issue by njx
Tuesday Mar 26, 2013 at 17:10 GMT
Originally opened as adobe/brackets#3253


  1. Turn on View > Highlight Active Line
  2. Open an inline editor
  3. Click in the inline editor
  4. Click back in the main editor

Result: Both editors always show active lines.
Expected: Active line should only show in focused editor.

@core-ai-bot
Copy link
Member Author

Comment by TomMalbran
Thursday Mar 28, 2013 at 04:36 GMT


I think this might need to be changed in the CodeMirror addon, or it would require a hack in Brackets to remove the highlight line class of the active line when the focus changes. An alternative would be to toggle Highlight Active Line it on and off to let the addon remove the classes.

@core-ai-bot
Copy link
Member Author

Comment by RaymondLim
Thursday Mar 28, 2013 at 04:46 GMT


@TomMalbran

I think we can handle it in Brackets by always setting a new "activeEditor" class to the active editor and remove that class when it is no longer active. Then we can add the new "activeEditor" class selector to all the rules that have ".CodeMirror-activeline-background" selector. Then split all the rules with ".CodeMirror-activeline-background" selector to two -- one with the new ".activeEditor"" class selector that has active-line background color and the other with ":not(.activeEditor)" class selector that has normal background color.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant