lib/watir-classic/element.rb in watir-classic-3.7.0 vs lib/watir-classic/element.rb in watir-classic-4.0.0

- old
+ new

@@ -359,11 +359,11 @@ end end # @private def dispatch_event(event) - if IE.version_parts.first.to_i >= 9 && container.page_container.document.documentMode.to_i >= 9 + if Browser.version_parts.first.to_i >= 9 && container.page_container.document.documentMode.to_i >= 9 ole_object.dispatchEvent(create_event(event)) else ole_object.fireEvent(event) end end @@ -452,10 +452,10 @@ # needs to be done like this to avoid segfault on ruby 1.9.3 tag_name = @specifiers[:tag_name].join("' << '") element = "#{self.class}.new(#{@page_container.attach_command}, :tag_name => Array.new << '#{tag_name}', :unique_number => #{unique_number})" method = build_method(method_name, *args) ruby_code = "$:.unshift(#{$LOAD_PATH.map {|p| "'#{p}'" }.join(").unshift(")});" << - "require '#{File.expand_path(File.dirname(__FILE__))}/core';#{element}.#{method};" + "require '#{File.expand_path(File.dirname(__FILE__))}/../watir-classic';#{element}.#{method};" ruby_code end def spawned_no_wait_command(command) command = "-e #{command.inspect}"