Introduced major-mode. Changed key bindings for the minor-mode. Removed duplicated code.