Method: Watir::IE#speed=
- Defined in:
- lib/watir/ie-class.rb
#speed=(how_fast) ⇒ Object
Specifies the speed that commands will be executed at. Choices are:
-
:slow (default)
-
:fast
-
:zippy
With IE#speed= :zippy, text fields will be entered at once, instead of character by character (default).
190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 |
# File 'lib/watir/ie-class.rb', line 190 def speed= how_fast case how_fast when :zippy then @typingspeed = 0 @pause_after_wait = 0.01 @type_keys = false @speed = :fast when :fast then @typingspeed = 0 @pause_after_wait = 0.01 @type_keys = true @speed = :fast when :slow then @typingspeed = 0.08 @pause_after_wait = 0.1 @type_keys = true @speed = :slow else raise ArgumentError, "Invalid speed: #{how_fast}" end end |