watir/watir-classic — pull request #70 by jkotests (2014-12-06 05:59:21+00:00)
Title: Add Element#to_subtype support for button, text and file inputs

As identified by the Watirspec Element#to_subtype examples proposed in watir/watirspec#51, the method was not handling certain input types. In particular, the text, submit, reset, image and file types were failing.

The code for handling input tags was:

````ruby
send(ole_object.invoke('type'), :ole_object => ole_object)
````

This meant that the "text" input type would try to create a TextField instance by using the method `text` rather than `text_field`. Similar could be seen with the other input types. This pull request adds a mapping between the type and required method.

Additional notes:
* The `tag == "select"` branch of the if statement was removed. Given that `select` is now an alias of `select_list`, the select elements are covered by the `respond_to?(tag)` branch.