Build fix for overlay.

Compute keyboard mod state once.
Fix C++ 'new' usage.
(GX) Jacobeian changes
(Android) Build fix