Factored out common behaviour
Issue #12
Allow to move elements in the tree.