Hi guys,
I''m building a class that handles functions for both IE and FF.
The trubble is that when I pass a class (e.g. for IE), I can''t use
normal functionality.
A wee example below. the browser.goto("http://www.nu.nl") command
fails.
class BIE <IE
	def initialize
		#@ff = FireWatir::Firefox.new()
		#@IE = Internetexplorer.new()
		@strBrowserType = ''IE''
		@browser ||= Watir::IE.new; @browser.speed = :fast
		puts "new IE instance"
	end
	def talk
		puts "talking IE"
	end
	def ggoto(url)
		@browser.goto(url)
	end
end
class Browser
	def initialize
		#@browserIE = new BIE
		#@browserFF = new BFF
		@strBType = "FF"
		#@browserIE.retrieveSettings()
		#@strBType = @browserIE.getBrowserType()
	end
	 def BrowserChoice()
		# case select
		  # what browser in start.xls
		# end
		puts "in browserchoice"
		 test = BIE.new
		 return test
	 end
end
#option 1
	b = Browser.new
	browser = b.BrowserChoice
	browser.talk()
	browser.goto("http://www.nu.nl")
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---