UI\Control: refactoring of template object creation

Now it is possible to override template object creation more easy and it is possible to customize it.