Refactored editor viewmodel; Fixes #27.