B2G/gaia/apps/keyboard/js/keyboard.js
// Map the input type to another type
Map the input type to another type
Map the input type to another type
function mapInputType(type) {
  switch (type) {
  case 'url':
  case 'tel':
  case 'email':
  case 'text':
    return type;
    break;
  case 'password':
  case 'search':
  default:
    return 'text';
    break;
  case 'number':
  case 'range': 
    return 'number';
    break;
  }
  return null;
}
function mapInputType ( type ) { switch ( type ) { case 'url' : case 'tel' : case 'email' : case 'text' : return type ; break ; case 'password' : case 'search' : default : return 'text' ; break ; case 'number' : case 'range' : return 'number' ; break ; } return null ; }
Map the input type to another type
Map the input type to another type
// basic types // default fallback and textual types // XXX: should be different from number