Localisation of key related variables.

At some point, the keyGroup structure should be wrappered up to prevent damge from outside.  However, it is accessed from elsewhere in rinLibrary and from one of the examples.