removed dynamic constant becasuse i was being a bad programer

This commit is contained in:
Scott Davis 2011-04-01 22:19:24 -04:00
parent 7ffde70c8d
commit 8a1f14d72d
2 changed files with 4 additions and 3 deletions

View File

@ -7,7 +7,7 @@ GIT
PATH PATH
remote: . remote: .
specs: specs:
compass (0.11.beta.5.23f0f03) compass (0.11.beta.5.7ffde70)
chunky_png (~> 1.1.0) chunky_png (~> 1.1.0)
sass (>= 3.1.0.alpha.249) sass (>= 3.1.0.alpha.249)

View File

@ -1,5 +1,6 @@
module Compass module Compass
module Configuration module Configuration
@callbacks_loaded = false
# The helpers are available as methods on the Compass module. E.g. Compass.configuration # The helpers are available as methods on the Compass module. E.g. Compass.configuration
module Helpers module Helpers
def configuration def configuration
@ -65,14 +66,14 @@ module Compass
Sass::Plugin.add_template_location sass_dir, css_dir Sass::Plugin.add_template_location sass_dir, css_dir
end end
end end
unless defined?(CallbacksSetup) unless @callbacks_loaded
Sass::Plugin.on_updating_stylesheet do |sass_file, css_file| Sass::Plugin.on_updating_stylesheet do |sass_file, css_file|
Compass.configuration.run_callback(:stylesheet_saved, css_file) Compass.configuration.run_callback(:stylesheet_saved, css_file)
end end
Sass::Plugin.on_compilation_error do |e, filename, css| Sass::Plugin.on_compilation_error do |e, filename, css|
Compass.configuration.run_callback(:stylesheet_error, filename, e.message) Compass.configuration.run_callback(:stylesheet_error, filename, e.message)
end end
const_set('CallbacksSetup', true) @callbacks_loaded = true
end end
end end