Commit 87d14dea authored by Jean-Philippe Lang's avatar Jean-Philippe Lang

Fixes SVG lib for ruby1.9.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3017 e93f8b46-1217-0410-a6f0-8f06a7374b81
parent 86a9d90f
...@@ -150,7 +150,7 @@ module SVG ...@@ -150,7 +150,7 @@ module SVG
:add_popups =>false, :add_popups =>false,
}) })
set_defaults if methods.include? "set_defaults" set_defaults if respond_to? :set_defaults
init_with config init_with config
end end
...@@ -195,7 +195,7 @@ module SVG ...@@ -195,7 +195,7 @@ module SVG
def burn def burn
raise "No data available" unless @data.size > 0 raise "No data available" unless @data.size > 0
calculations if methods.include? 'calculations' calculations if respond_to? :calculations
start_svg start_svg
calculate_graph_dimensions calculate_graph_dimensions
...@@ -355,7 +355,7 @@ module SVG ...@@ -355,7 +355,7 @@ module SVG
# by subclasses. # by subclasses.
def init_with config def init_with config
config.each { |key, value| config.each { |key, value|
self.send( key.to_s+"=", value ) if methods.include? key.to_s self.send((key.to_s+"=").to_sym, value ) if respond_to? key.to_sym
} }
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment