work with i18n-js rewrite branch as it supports rails 3.2

pull/1186/head
Philipp Tessenow 12 years ago
parent 140e53ca53
commit 2b7e87d003
  1. 2
      Gemfile
  2. 12
      Gemfile.lock
  3. 1
      app/assets/javascripts/application.js
  4. 3
      config/application.rb
  5. 6
      config/initializers/i18n-js.rb

@ -39,7 +39,7 @@ end
gem "prototype-rails"
gem 'jquery-rails'
gem "i18n-js"
gem "i18n-js", :git => "git://github.com/fnando/i18n-js.git", :branch => "rewrite"
group :test do
gem 'shoulda', '~> 3.1.1'

@ -4,6 +4,14 @@ GIT
specs:
object-daddy (1.1.0)
GIT
remote: git://github.com/fnando/i18n-js.git
revision: 689f4d709285cccfef9f5e10b295d9b2fe63d519
branch: rewrite
specs:
i18n-js (3.0.0.rc3)
i18n
GIT
remote: git://github.com/rails/rails.git
revision: b4f189a162f4280b360dbc2a6635bbff6c6f09bc
@ -148,8 +156,6 @@ GEM
hike (1.2.1)
htmldiff (0.0.1)
i18n (0.6.1)
i18n-js (2.1.2)
i18n
interception (0.3)
journey (1.0.4)
jquery-rails (2.2.0)
@ -336,7 +342,7 @@ DEPENDENCIES
guard-spork
guard-test
htmldiff
i18n-js
i18n-js!
jquery-rails
jquery-ui-rails
jruby-openssl

@ -26,7 +26,6 @@
//= require context_menu
//= require jstoolbar
//= require calendar
//= require i18n
//= require i18n/translations
//source: http://stackoverflow.com/questions/8120065/jquery-and-prototype-dont-work-together-with-array-prototype-reverse

@ -43,6 +43,9 @@ module OpenProject
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
# config.i18n.default_locale = :de
# automatically compile translations.js
config.middleware.use I18n::JS::Middleware
# Configure the default encoding used in templates for Ruby 1.9.
config.encoding = "utf-8"

@ -24,8 +24,8 @@
# not seem to accept even the simplest pull request. We should try again, when
# the `rewrite` branch of i18n-js is released to master.
#
# Written against i18n-js v2.1.2
SimplesIdeias::I18n.module_eval do
# Written against i18n-js rewrite branch
I18n::JS.module_eval do
class << self
def filter_with_uneven_nesting_fix(translations, scopes)
filter_without_uneven_nesting_fix(translations, scopes) if translations.is_a? Hash
@ -35,4 +35,4 @@ SimplesIdeias::I18n.module_eval do
end
# Exporting I18n files at server startup time
SimplesIdeias::I18n.export!
I18n::JS.export

Loading…
Cancel
Save