Implemented two-way binding for tree selection, misc selection fixes

And a lot of import optimizations.