fix #376 Issues in html TextInput widget

- Autoselection occurring even when the field already had focus
- Placeholder text in browsers that do not support the native implementation was selectable
fix #379 TemplateCtxt.getDomId does not support integers.

Closes #380.