clemos / haxe-sublime-bundle

Sublime Text bundle for Haxe programming language
Apache License 2.0
237 stars 86 forks source link

Fix bug where searching would trigger documentation view. #116

Closed johnfn closed 10 years ago

johnfn commented 10 years ago

Fix the bug I mentioned in the previous pull request :)

(Oh, and if you know a better way to check this, let me know...)

clemos commented 10 years ago

To avoid having other methods of the plugin running for every type of files, we do this :

if view.score_selector(0,'source.haxe.2') > 0 :

It checks that we are currently in a Haxe source file. I believe it's a good idea to add this anyway, and it might also solve this issue with search in a cleaner way ?...

johnfn commented 10 years ago

Added!

But unfortunately, my tests showed that the value of view.score_selector(0, 'source.haxe.2') doesn't change if you go into the find window, so I've left my approach in the code as is for now.

clemos commented 10 years ago

I don't think I understand what bug it fixed, but thanks anyway :)