Removes the dependencies to project explorer and text editor plugins and moves unrelated code to its own file.