Code cleanup of ControlFactory.
Regenerated lua bindings.
Merge pull request #1215 from seanpaultaylor/next

Code cleanup of ControlFactory.