refactored initialization of codemirror: moved code from jsni methods in java, to regular yasgui javascript file