Bug 1111438 - KeyboardManager clean-up

- Reduce showingLayoutInfo to showingInputGroup, which now only restores the current input type group; the activeLayout index and the layout itself has to be consulted from inputLayouts. This avoids unnecessary bookkeeping.

- Explicitly separate the "preload" concept from setKeyboardToShow to reduce if-else complexity in the function (and to make setKeyboardToShow less god)

- Renamed InputLayouts.layouts.group.activeLayout to activeLayoutIdx to better reflect the idea that it stores an index.

- Mandated that activeLayoutIdx should not be written by KeyboardManager.
Bug 1104913 - Change app to rely upon optimal default selection chosen by gecko.
Merge pull request #26776 from mnjul/bug_1111438_keyboardmanager_cleanup

Bug 1111438 - KeyboardManager clean-up. r=timdream, f=mhenretty
Merge pull request #26720 from aosmond/bug1104913

Bug 1104913 - Change app to rely upon optimal default selection chosen by gecko.