Move commands into static getter so they can be overridden.

Also key groups by name. This makes it easiers for overriding classes
to add extra keyboard shortcuts (e.g. MediaWiki specific shortcuts).

Change-Id: I4d84df7b5992e83b2ac296865a64f301fe5b2e22
Merge "Move commands into static getter so they can be overridden."