jpmobile 2.0.7 → 2.0.8
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +3 -3
- data/VERSION.yml +3 -3
- data/jpmobile.gemspec +1 -1
- data/lib/jpmobile.rb +6 -1
- data/lib/jpmobile/mobile/abstract_mobile.rb +51 -33
- data/lib/jpmobile/mobile/android_tablet.rb +10 -0
- data/lib/jpmobile/mobile/ipad.rb +10 -0
- data/lib/jpmobile/mobile/tablet.rb +16 -0
- data/spec/rack/jpmobile/mobile_by_ua_spec.rb +4 -1
- data/test/rails/overrides/Gemfile +4 -4
- data/test/rails/overrides/app/controllers/template_path_controller.rb +12 -0
- data/test/rails/overrides/app/views/template_path/smart_phone_only.html.erb +1 -0
- data/test/rails/overrides/app/views/template_path/smart_phone_only_smart_phone.html.erb +1 -0
- data/test/rails/overrides/app/views/template_path/with_ipd.html.erb +1 -0
- data/test/rails/overrides/app/views/template_path/with_ipd_tablet_ipad.html.erb +1 -0
- data/test/rails/overrides/app/views/template_path/with_tblt.html.erb +1 -0
- data/test/rails/overrides/app/views/template_path/with_tblt_tablet.html.erb +1 -0
- data/test/rails/overrides/spec/requests/template_path_spec.rb +72 -0
- metadata +268 -161
data/Gemfile
CHANGED
@@ -3,9 +3,9 @@ source 'http://rubygems.org'
|
|
3
3
|
group :development, :test do
|
4
4
|
gem 'mail', '~> 2.3.0'
|
5
5
|
gem 'jeweler'
|
6
|
-
gem 'rails', '~> 3.1.
|
7
|
-
gem 'rspec'
|
8
|
-
gem 'rspec-rails'
|
6
|
+
gem 'rails', '~> 3.1.4'
|
7
|
+
gem 'rspec', '~> 2.8.0'
|
8
|
+
gem 'rspec-rails', '~> 2.8.0'
|
9
9
|
gem 'webrat'
|
10
10
|
gem 'geokit'
|
11
11
|
gem 'sqlite3-ruby'
|
data/VERSION.yml
CHANGED
data/jpmobile.gemspec
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{jpmobile}
|
8
|
-
s.version = "2.0.
|
8
|
+
s.version = "2.0.8"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Yoji Shidara", "Shin-ichiro OGAWA"]
|
data/lib/jpmobile.rb
CHANGED
@@ -22,14 +22,19 @@ module Jpmobile
|
|
22
22
|
autoload :Emobile, 'jpmobile/mobile/emobile'
|
23
23
|
autoload :Willcom, 'jpmobile/mobile/willcom'
|
24
24
|
autoload :Ddipocket, 'jpmobile/mobile/ddipocket'
|
25
|
+
|
25
26
|
autoload :SmartPhone, 'jpmobile/mobile/smart_phone'
|
26
27
|
autoload :Iphone, 'jpmobile/mobile/iphone'
|
27
28
|
autoload :Android, 'jpmobile/mobile/android'
|
28
29
|
autoload :WindowsPhone, 'jpmobile/mobile/windows_phone'
|
29
30
|
|
31
|
+
autoload :Tablet, 'jpmobile/mobile/tablet'
|
32
|
+
autoload :AndroidTablet, 'jpmobile/mobile/android_tablet'
|
33
|
+
autoload :Ipad, 'jpmobile/mobile/ipad'
|
34
|
+
|
30
35
|
autoload :Display, 'jpmobile/mobile/display'
|
31
36
|
|
32
|
-
DEFAULT_CARRIERS = %w(Docomo Au Softbank Vodafone Emobile Willcom Ddipocket Iphone Android WindowsPhone)
|
37
|
+
DEFAULT_CARRIERS = %w(Docomo Au Softbank Vodafone Emobile Willcom Ddipocket Ipad AndroidTablet Iphone Android WindowsPhone)
|
33
38
|
|
34
39
|
def self.carriers
|
35
40
|
@carriers ||= DEFAULT_CARRIERS.dup
|
@@ -29,16 +29,6 @@ module Jpmobile::Mobile
|
|
29
29
|
# 端末を識別する文字列があれば返す。
|
30
30
|
def ident_device; nil; end
|
31
31
|
|
32
|
-
# 当該キャリアのIPアドレス帯域からのアクセスであれば +true+ を返す。
|
33
|
-
# そうでなければ +false+ を返す。
|
34
|
-
# IP空間が定義されていない場合は +nil+ を返す。
|
35
|
-
def self.valid_ip? remote_addr
|
36
|
-
@ip_list ||= ip_address_class
|
37
|
-
return false unless @ip_list
|
38
|
-
|
39
|
-
@ip_list.valid_ip?(remote_addr)
|
40
|
-
end
|
41
|
-
|
42
32
|
def valid_ip?
|
43
33
|
@__valid_ip ||= self.class.valid_ip? @request.ip
|
44
34
|
end
|
@@ -60,6 +50,11 @@ module Jpmobile::Mobile
|
|
60
50
|
false
|
61
51
|
end
|
62
52
|
|
53
|
+
# tablet かどうか
|
54
|
+
def tablet?
|
55
|
+
false
|
56
|
+
end
|
57
|
+
|
63
58
|
# Jpmobile::Rack::Filter を適用するかどうか
|
64
59
|
def apply_filter?
|
65
60
|
true
|
@@ -90,6 +85,7 @@ module Jpmobile::Mobile
|
|
90
85
|
gsub(/Jpmobile::/, '').
|
91
86
|
gsub(/AbstractMobile::/, '').
|
92
87
|
gsub(/Mobile::SmartPhone/, 'smart_phone').
|
88
|
+
gsub(/Mobile::Tablet/, 'tablet').
|
93
89
|
gsub(/::/, '_').
|
94
90
|
gsub(/([A-Z]+)([A-Z][a-z])/, '\1_\2').
|
95
91
|
gsub(/([a-z\d])([A-Z])/, '\1_\2').
|
@@ -97,8 +93,10 @@ module Jpmobile::Mobile
|
|
97
93
|
klass =~ /abstract/ ? "mobile" : klass
|
98
94
|
end
|
99
95
|
|
100
|
-
if @_variants.include?(
|
101
|
-
@_variants = @_variants.reject{|v| v == "mobile"}.map{|v| v.gsub(/
|
96
|
+
if @_variants.include?('tablet')
|
97
|
+
@_variants = @_variants.reject{|v| v == "mobile"}.map{|v| v.gsub(/mobile_/, "tablet_")}
|
98
|
+
elsif @_variants.include?("smart_phone")
|
99
|
+
@_variants = @_variants.reject{|v| v == "mobile"}.map{|v| v.gsub(/mobile_/, "smart_phone_")}
|
102
100
|
end
|
103
101
|
|
104
102
|
@_variants || []
|
@@ -174,10 +172,47 @@ module Jpmobile::Mobile
|
|
174
172
|
@decorated
|
175
173
|
end
|
176
174
|
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
175
|
+
class << self
|
176
|
+
# 当該キャリアのIPアドレス帯域からのアクセスであれば +true+ を返す。
|
177
|
+
# そうでなければ +false+ を返す。
|
178
|
+
# IP空間が定義されていない場合は +nil+ を返す。
|
179
|
+
def valid_ip? remote_addr
|
180
|
+
@ip_list ||= ip_address_class
|
181
|
+
return false unless @ip_list
|
182
|
+
|
183
|
+
@ip_list.valid_ip?(remote_addr)
|
184
|
+
end
|
185
|
+
|
186
|
+
# リクエストがこのクラスに属するか調べる
|
187
|
+
# メソッド名に関して非常に不安
|
188
|
+
def check_carrier(env)
|
189
|
+
user_agent_regexp && user_agent_regexp.match(env['HTTP_USER_AGENT'])
|
190
|
+
end
|
191
|
+
|
192
|
+
def user_agent_regexp
|
193
|
+
@_user_agent_regexp ||= self::USER_AGENT_REGEXP
|
194
|
+
end
|
195
|
+
|
196
|
+
def add_user_agent_regexp(regexp)
|
197
|
+
@_user_agent_regexp = Regexp.union(user_agent_regexp, regexp)
|
198
|
+
end
|
199
|
+
|
200
|
+
def carrier(env)
|
201
|
+
::Jpmobile::Mobile.carriers.each do |const|
|
202
|
+
c = ::Jpmobile::Mobile.const_get(const)
|
203
|
+
if c.check_carrier(env)
|
204
|
+
res = ::Rack::Request.new(env)
|
205
|
+
return c.new(env, res)
|
206
|
+
end
|
207
|
+
end
|
208
|
+
|
209
|
+
nil
|
210
|
+
end
|
211
|
+
|
212
|
+
#
|
213
|
+
def ip_address_class
|
214
|
+
eval("::Jpmobile::Mobile::IpAddresses::#{self.to_s.split(/::/).last}").new rescue nil
|
215
|
+
end
|
181
216
|
end
|
182
217
|
|
183
218
|
#XXX: lib/jpmobile.rbのautoloadで先に各キャリアの定数を定義しているから動くのです
|
@@ -190,18 +225,6 @@ module Jpmobile::Mobile
|
|
190
225
|
end
|
191
226
|
end
|
192
227
|
|
193
|
-
def self.carrier(env)
|
194
|
-
::Jpmobile::Mobile.carriers.each do |const|
|
195
|
-
c = ::Jpmobile::Mobile.const_get(const)
|
196
|
-
if c.check_carrier(env)
|
197
|
-
res = ::Rack::Request.new(env)
|
198
|
-
return c.new(env, res)
|
199
|
-
end
|
200
|
-
end
|
201
|
-
|
202
|
-
nil
|
203
|
-
end
|
204
|
-
|
205
228
|
private
|
206
229
|
# リクエストのパラメータ。
|
207
230
|
def params
|
@@ -211,10 +234,5 @@ module Jpmobile::Mobile
|
|
211
234
|
@request.params
|
212
235
|
end
|
213
236
|
end
|
214
|
-
|
215
|
-
#
|
216
|
-
def self.ip_address_class
|
217
|
-
eval("::Jpmobile::Mobile::IpAddresses::#{self.to_s.split(/::/).last}").new rescue nil
|
218
|
-
end
|
219
237
|
end
|
220
238
|
end
|
@@ -19,8 +19,11 @@ describe Jpmobile::Rack::MobileCarrier do
|
|
19
19
|
[ Jpmobile::Mobile::Iphone , 'Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_0 like Mac OS X; ja-jp) AppleWebKit/528.18 (KHTML, like Gecko) Version/4.0 Mobile/7A341 Safari/528.16' ],
|
20
20
|
[ Jpmobile::Mobile::Android , 'Mozilla/5.0 (Linux; U; Android 1.6; ja-jp; SonyEriccsonSO-01B Build/R1EA018) AppleWebKit/528.5+ (KHTML, like Gecko) Version/3.1.2 Mobile Safari/525.20.1' ],
|
21
21
|
[ Jpmobile::Mobile::WindowsPhone , 'Mozilla/4.0 (Compatible; MSIE 6.0; Windows NT 5.1 T-01A_6.5; Windows Phone 6.5)' ],
|
22
|
+
[ Jpmobile::Mobile::Ipad , 'Mozilla/5.0 (iPad; U; CPU OS 4_3 like Mac OS X; ja-jp) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8F191 Safari/6533.18.5'],
|
23
|
+
[ Jpmobile::Mobile::AndroidTablet, 'Mozilla/5.0 (Linux; U; Android 2.2; ja-jp; SC-01C Build/FROYO) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1'],
|
24
|
+
[ Jpmobile::Mobile::AndroidTablet, 'Mozilla/5.0 (Linux; U; Android 3.2; ja-jp; Sony Tablet S Build/THMAS11002) AppleWebKit/534.13 (KHTML, like Gecko) Version/4.0 Safari/534.13'],
|
22
25
|
].each do |carrier, user_agent|
|
23
|
-
it
|
26
|
+
it "#mobile should return #{carrier} when take #{user_agent} as UserAgent" do
|
24
27
|
res = Rack::MockRequest.env_for(
|
25
28
|
'http://jpmobile-rails.org/',
|
26
29
|
'HTTP_USER_AGENT' => user_agent)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
source 'http://rubygems.org'
|
2
2
|
|
3
|
-
gem 'rails', '~> 3.1.
|
4
|
-
gem 'mail', '2.3.0'
|
3
|
+
gem 'rails', '~> 3.1.4'
|
4
|
+
gem 'mail', '~> 2.3.0'
|
5
5
|
|
6
6
|
# Bundle edge Rails instead:
|
7
7
|
# gem 'rails', :git => 'git://github.com/rails/rails.git'
|
@@ -28,7 +28,7 @@ gem 'hpricot'
|
|
28
28
|
|
29
29
|
# Bundle gems for certain environments:
|
30
30
|
group :development, :test do
|
31
|
-
gem "rspec", ">= 2.
|
32
|
-
gem "rspec-rails", ">= 2.
|
31
|
+
gem "rspec", ">= 2.8.0"
|
32
|
+
gem "rspec-rails", ">= 2.8.0"
|
33
33
|
gem 'webrat'
|
34
34
|
end
|
@@ -13,5 +13,17 @@ class TemplatePathController < ApplicationController
|
|
13
13
|
def optioned_index
|
14
14
|
render :action => "index"
|
15
15
|
end
|
16
|
+
|
17
|
+
def full_path_partial
|
18
|
+
end
|
19
|
+
|
20
|
+
def smart_phone_only
|
21
|
+
end
|
22
|
+
|
23
|
+
def with_tblt
|
24
|
+
end
|
25
|
+
|
26
|
+
def with_ipd
|
27
|
+
end
|
16
28
|
end
|
17
29
|
|
@@ -0,0 +1 @@
|
|
1
|
+
<h1>smart_phone_only.html.erb</h1>
|
@@ -0,0 +1 @@
|
|
1
|
+
<h1>smart_phone_only_smart_phone.html.erb</h1>
|
@@ -0,0 +1 @@
|
|
1
|
+
<h1>with_ipd.html.erb</h1>
|
@@ -0,0 +1 @@
|
|
1
|
+
<h1>with_ipd_tablet_ipad.html.erb</h1>
|
@@ -0,0 +1 @@
|
|
1
|
+
<h1>with_tblt.html.erb</h1>
|
@@ -0,0 +1 @@
|
|
1
|
+
<h1>with_tblt_tablet.html.erb</h1>
|
@@ -169,6 +169,78 @@ describe TemplatePathController, "integrated_views" do
|
|
169
169
|
end
|
170
170
|
end
|
171
171
|
|
172
|
+
context 'only smart_phone view' do
|
173
|
+
context 'iPadからのアクセスの場合' do
|
174
|
+
before do
|
175
|
+
@user_agent = 'Mozilla/5.0 (iPad; U; CPU OS 4_3 like Mac OS X; ja-jp) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8F191 Safari/6533.18.5'
|
176
|
+
end
|
177
|
+
it 'smart_phone_only.html.erbが使用されること' do
|
178
|
+
get '/template_path/smart_phone_only', {}, {'HTTP_USER_AGENT' => @user_agent}
|
179
|
+
|
180
|
+
response.should have_tag('h1', :content => 'smart_phone_only_smart_phone.html.erb')
|
181
|
+
end
|
182
|
+
end
|
183
|
+
|
184
|
+
context 'Android Tabletからのアクセスの場合' do
|
185
|
+
before do
|
186
|
+
@user_agent = 'Mozilla/5.0 (Linux; U; Android 2.2; ja-jp; SC-01C Build/FROYO) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1'
|
187
|
+
end
|
188
|
+
it 'smart_phone_only.html.erbが使用されること' do
|
189
|
+
get '/template_path/smart_phone_only', {}, {'HTTP_USER_AGENT' => @user_agent}
|
190
|
+
|
191
|
+
response.should have_tag('h1', :content => 'smart_phone_only_smart_phone.html.erb')
|
192
|
+
end
|
193
|
+
end
|
194
|
+
end
|
195
|
+
|
196
|
+
context 'with_tblt view' do
|
197
|
+
context 'iPadからのアクセスの場合' do
|
198
|
+
before do
|
199
|
+
@user_agent = 'Mozilla/5.0 (iPad; U; CPU OS 4_3 like Mac OS X; ja-jp) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8F191 Safari/6533.18.5'
|
200
|
+
end
|
201
|
+
it 'with_tblt_tablet.html.erbが使用されること' do
|
202
|
+
get '/template_path/with_tblt', {}, {'HTTP_USER_AGENT' => @user_agent}
|
203
|
+
|
204
|
+
response.should have_tag('h1', :content => 'with_tblt_tablet.html.erb')
|
205
|
+
end
|
206
|
+
end
|
207
|
+
|
208
|
+
context 'Android Tabletからのアクセスの場合' do
|
209
|
+
before do
|
210
|
+
@user_agent = 'Mozilla/5.0 (Linux; U; Android 2.2; ja-jp; SC-01C Build/FROYO) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1'
|
211
|
+
end
|
212
|
+
it 'with_tblt_tablet.html.erbが使用されること' do
|
213
|
+
get '/template_path/with_tblt', {}, {'HTTP_USER_AGENT' => @user_agent}
|
214
|
+
|
215
|
+
response.should have_tag('h1', :content => 'with_tblt_tablet.html.erb')
|
216
|
+
end
|
217
|
+
end
|
218
|
+
end
|
219
|
+
|
220
|
+
context 'with_ipd view' do
|
221
|
+
context 'iPadからのアクセスの場合' do
|
222
|
+
before do
|
223
|
+
@user_agent = 'Mozilla/5.0 (iPad; U; CPU OS 4_3 like Mac OS X; ja-jp) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8F191 Safari/6533.18.5'
|
224
|
+
end
|
225
|
+
it 'with_ipd_tablet_ipad.html.erbが使用されること' do
|
226
|
+
get '/template_path/with_ipd', {}, {'HTTP_USER_AGENT' => @user_agent}
|
227
|
+
|
228
|
+
response.should have_tag('h1', :content => 'with_ipd_tablet_ipad.html.erb')
|
229
|
+
end
|
230
|
+
end
|
231
|
+
|
232
|
+
context 'Android Tabletからのアクセスの場合' do
|
233
|
+
before do
|
234
|
+
@user_agent = 'Mozilla/5.0 (Linux; U; Android 2.2; ja-jp; SC-01C Build/FROYO) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1'
|
235
|
+
end
|
236
|
+
it 'with_ipd.html.erbが使用されること' do
|
237
|
+
get '/template_path/with_ipd', {}, {'HTTP_USER_AGENT' => @user_agent}
|
238
|
+
|
239
|
+
response.should have_tag('h1', :content => 'with_ipd.html.erb')
|
240
|
+
end
|
241
|
+
end
|
242
|
+
end
|
243
|
+
|
172
244
|
context "partial" do
|
173
245
|
context "PCからのアクセスの場合" do
|
174
246
|
before do
|
metadata
CHANGED
@@ -1,223 +1,311 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: jpmobile
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
hash: 31
|
5
5
|
prerelease:
|
6
|
+
segments:
|
7
|
+
- 2
|
8
|
+
- 0
|
9
|
+
- 8
|
10
|
+
version: 2.0.8
|
6
11
|
platform: ruby
|
7
|
-
authors:
|
12
|
+
authors:
|
8
13
|
- Yoji Shidara
|
9
14
|
- Shin-ichiro OGAWA
|
10
15
|
autorequire:
|
11
16
|
bindir: bin
|
12
17
|
cert_chain: []
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
requirement: &
|
18
|
+
|
19
|
+
date: 2012-05-16 00:00:00 Z
|
20
|
+
dependencies:
|
21
|
+
- !ruby/object:Gem::Dependency
|
22
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
18
23
|
none: false
|
19
|
-
requirements:
|
24
|
+
requirements:
|
20
25
|
- - ~>
|
21
|
-
- !ruby/object:Gem::Version
|
26
|
+
- !ruby/object:Gem::Version
|
27
|
+
hash: 3
|
28
|
+
segments:
|
29
|
+
- 2
|
30
|
+
- 3
|
31
|
+
- 0
|
22
32
|
version: 2.3.0
|
33
|
+
prerelease: false
|
34
|
+
name: mail
|
23
35
|
type: :development
|
36
|
+
version_requirements: *id001
|
37
|
+
- !ruby/object:Gem::Dependency
|
38
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ">="
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
hash: 3
|
44
|
+
segments:
|
45
|
+
- 0
|
46
|
+
version: "0"
|
24
47
|
prerelease: false
|
25
|
-
version_requirements: *16558240
|
26
|
-
- !ruby/object:Gem::Dependency
|
27
48
|
name: jeweler
|
28
|
-
requirement: &16555980 !ruby/object:Gem::Requirement
|
29
|
-
none: false
|
30
|
-
requirements:
|
31
|
-
- - ! '>='
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: '0'
|
34
49
|
type: :development
|
50
|
+
version_requirements: *id002
|
51
|
+
- !ruby/object:Gem::Dependency
|
52
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
53
|
+
none: false
|
54
|
+
requirements:
|
55
|
+
- - ~>
|
56
|
+
- !ruby/object:Gem::Version
|
57
|
+
hash: 11
|
58
|
+
segments:
|
59
|
+
- 3
|
60
|
+
- 1
|
61
|
+
- 4
|
62
|
+
version: 3.1.4
|
35
63
|
prerelease: false
|
36
|
-
version_requirements: *16555980
|
37
|
-
- !ruby/object:Gem::Dependency
|
38
64
|
name: rails
|
39
|
-
|
65
|
+
type: :development
|
66
|
+
version_requirements: *id003
|
67
|
+
- !ruby/object:Gem::Dependency
|
68
|
+
requirement: &id004 !ruby/object:Gem::Requirement
|
40
69
|
none: false
|
41
|
-
requirements:
|
70
|
+
requirements:
|
42
71
|
- - ~>
|
43
|
-
- !ruby/object:Gem::Version
|
44
|
-
|
45
|
-
|
72
|
+
- !ruby/object:Gem::Version
|
73
|
+
hash: 47
|
74
|
+
segments:
|
75
|
+
- 2
|
76
|
+
- 8
|
77
|
+
- 0
|
78
|
+
version: 2.8.0
|
46
79
|
prerelease: false
|
47
|
-
version_requirements: *16627280
|
48
|
-
- !ruby/object:Gem::Dependency
|
49
80
|
name: rspec
|
50
|
-
requirement: &16625740 !ruby/object:Gem::Requirement
|
51
|
-
none: false
|
52
|
-
requirements:
|
53
|
-
- - ! '>='
|
54
|
-
- !ruby/object:Gem::Version
|
55
|
-
version: '0'
|
56
81
|
type: :development
|
82
|
+
version_requirements: *id004
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
requirement: &id005 !ruby/object:Gem::Requirement
|
85
|
+
none: false
|
86
|
+
requirements:
|
87
|
+
- - ~>
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
hash: 47
|
90
|
+
segments:
|
91
|
+
- 2
|
92
|
+
- 8
|
93
|
+
- 0
|
94
|
+
version: 2.8.0
|
57
95
|
prerelease: false
|
58
|
-
version_requirements: *16625740
|
59
|
-
- !ruby/object:Gem::Dependency
|
60
96
|
name: rspec-rails
|
61
|
-
requirement: &16623860 !ruby/object:Gem::Requirement
|
62
|
-
none: false
|
63
|
-
requirements:
|
64
|
-
- - ! '>='
|
65
|
-
- !ruby/object:Gem::Version
|
66
|
-
version: '0'
|
67
97
|
type: :development
|
98
|
+
version_requirements: *id005
|
99
|
+
- !ruby/object:Gem::Dependency
|
100
|
+
requirement: &id006 !ruby/object:Gem::Requirement
|
101
|
+
none: false
|
102
|
+
requirements:
|
103
|
+
- - ">="
|
104
|
+
- !ruby/object:Gem::Version
|
105
|
+
hash: 3
|
106
|
+
segments:
|
107
|
+
- 0
|
108
|
+
version: "0"
|
68
109
|
prerelease: false
|
69
|
-
version_requirements: *16623860
|
70
|
-
- !ruby/object:Gem::Dependency
|
71
110
|
name: webrat
|
72
|
-
requirement: &16622600 !ruby/object:Gem::Requirement
|
73
|
-
none: false
|
74
|
-
requirements:
|
75
|
-
- - ! '>='
|
76
|
-
- !ruby/object:Gem::Version
|
77
|
-
version: '0'
|
78
111
|
type: :development
|
112
|
+
version_requirements: *id006
|
113
|
+
- !ruby/object:Gem::Dependency
|
114
|
+
requirement: &id007 !ruby/object:Gem::Requirement
|
115
|
+
none: false
|
116
|
+
requirements:
|
117
|
+
- - ">="
|
118
|
+
- !ruby/object:Gem::Version
|
119
|
+
hash: 3
|
120
|
+
segments:
|
121
|
+
- 0
|
122
|
+
version: "0"
|
79
123
|
prerelease: false
|
80
|
-
version_requirements: *16622600
|
81
|
-
- !ruby/object:Gem::Dependency
|
82
124
|
name: geokit
|
83
|
-
requirement: &16621500 !ruby/object:Gem::Requirement
|
84
|
-
none: false
|
85
|
-
requirements:
|
86
|
-
- - ! '>='
|
87
|
-
- !ruby/object:Gem::Version
|
88
|
-
version: '0'
|
89
125
|
type: :development
|
126
|
+
version_requirements: *id007
|
127
|
+
- !ruby/object:Gem::Dependency
|
128
|
+
requirement: &id008 !ruby/object:Gem::Requirement
|
129
|
+
none: false
|
130
|
+
requirements:
|
131
|
+
- - ">="
|
132
|
+
- !ruby/object:Gem::Version
|
133
|
+
hash: 3
|
134
|
+
segments:
|
135
|
+
- 0
|
136
|
+
version: "0"
|
90
137
|
prerelease: false
|
91
|
-
version_requirements: *16621500
|
92
|
-
- !ruby/object:Gem::Dependency
|
93
138
|
name: sqlite3-ruby
|
94
|
-
requirement: &16619900 !ruby/object:Gem::Requirement
|
95
|
-
none: false
|
96
|
-
requirements:
|
97
|
-
- - ! '>='
|
98
|
-
- !ruby/object:Gem::Version
|
99
|
-
version: '0'
|
100
139
|
type: :development
|
140
|
+
version_requirements: *id008
|
141
|
+
- !ruby/object:Gem::Dependency
|
142
|
+
requirement: &id009 !ruby/object:Gem::Requirement
|
143
|
+
none: false
|
144
|
+
requirements:
|
145
|
+
- - ">="
|
146
|
+
- !ruby/object:Gem::Version
|
147
|
+
hash: 3
|
148
|
+
segments:
|
149
|
+
- 0
|
150
|
+
version: "0"
|
101
151
|
prerelease: false
|
102
|
-
version_requirements: *16619900
|
103
|
-
- !ruby/object:Gem::Dependency
|
104
152
|
name: hpricot
|
105
|
-
requirement: &16748440 !ruby/object:Gem::Requirement
|
106
|
-
none: false
|
107
|
-
requirements:
|
108
|
-
- - ! '>='
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
111
153
|
type: :development
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
name: rails
|
116
|
-
requirement: &16745960 !ruby/object:Gem::Requirement
|
154
|
+
version_requirements: *id009
|
155
|
+
- !ruby/object:Gem::Dependency
|
156
|
+
requirement: &id010 !ruby/object:Gem::Requirement
|
117
157
|
none: false
|
118
|
-
requirements:
|
119
|
-
- -
|
120
|
-
- !ruby/object:Gem::Version
|
158
|
+
requirements:
|
159
|
+
- - ">="
|
160
|
+
- !ruby/object:Gem::Version
|
161
|
+
hash: 3
|
162
|
+
segments:
|
163
|
+
- 3
|
164
|
+
- 1
|
165
|
+
- 0
|
121
166
|
version: 3.1.0
|
122
|
-
type: :development
|
123
167
|
prerelease: false
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
168
|
+
name: rails
|
169
|
+
type: :development
|
170
|
+
version_requirements: *id010
|
171
|
+
- !ruby/object:Gem::Dependency
|
172
|
+
requirement: &id011 !ruby/object:Gem::Requirement
|
128
173
|
none: false
|
129
|
-
requirements:
|
130
|
-
- -
|
131
|
-
- !ruby/object:Gem::Version
|
174
|
+
requirements:
|
175
|
+
- - ">="
|
176
|
+
- !ruby/object:Gem::Version
|
177
|
+
hash: 1
|
178
|
+
segments:
|
179
|
+
- 1
|
180
|
+
- 5
|
181
|
+
- 1
|
132
182
|
version: 1.5.1
|
183
|
+
prerelease: false
|
184
|
+
name: jeweler
|
133
185
|
type: :development
|
186
|
+
version_requirements: *id011
|
187
|
+
- !ruby/object:Gem::Dependency
|
188
|
+
requirement: &id012 !ruby/object:Gem::Requirement
|
189
|
+
none: false
|
190
|
+
requirements:
|
191
|
+
- - ">="
|
192
|
+
- !ruby/object:Gem::Version
|
193
|
+
hash: 23
|
194
|
+
segments:
|
195
|
+
- 2
|
196
|
+
- 6
|
197
|
+
- 0
|
198
|
+
version: 2.6.0
|
134
199
|
prerelease: false
|
135
|
-
version_requirements: *16745000
|
136
|
-
- !ruby/object:Gem::Dependency
|
137
200
|
name: rspec
|
138
|
-
|
201
|
+
type: :development
|
202
|
+
version_requirements: *id012
|
203
|
+
- !ruby/object:Gem::Dependency
|
204
|
+
requirement: &id013 !ruby/object:Gem::Requirement
|
139
205
|
none: false
|
140
|
-
requirements:
|
141
|
-
- -
|
142
|
-
- !ruby/object:Gem::Version
|
206
|
+
requirements:
|
207
|
+
- - ">="
|
208
|
+
- !ruby/object:Gem::Version
|
209
|
+
hash: 23
|
210
|
+
segments:
|
211
|
+
- 2
|
212
|
+
- 6
|
213
|
+
- 0
|
143
214
|
version: 2.6.0
|
144
|
-
type: :development
|
145
215
|
prerelease: false
|
146
|
-
version_requirements: *16744280
|
147
|
-
- !ruby/object:Gem::Dependency
|
148
216
|
name: rspec-rails
|
149
|
-
requirement: &16743540 !ruby/object:Gem::Requirement
|
150
|
-
none: false
|
151
|
-
requirements:
|
152
|
-
- - ! '>='
|
153
|
-
- !ruby/object:Gem::Version
|
154
|
-
version: 2.6.0
|
155
217
|
type: :development
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
name: webrat
|
160
|
-
requirement: &16742780 !ruby/object:Gem::Requirement
|
218
|
+
version_requirements: *id013
|
219
|
+
- !ruby/object:Gem::Dependency
|
220
|
+
requirement: &id014 !ruby/object:Gem::Requirement
|
161
221
|
none: false
|
162
|
-
requirements:
|
163
|
-
- -
|
164
|
-
- !ruby/object:Gem::Version
|
222
|
+
requirements:
|
223
|
+
- - ">="
|
224
|
+
- !ruby/object:Gem::Version
|
225
|
+
hash: 7
|
226
|
+
segments:
|
227
|
+
- 0
|
228
|
+
- 7
|
229
|
+
- 2
|
165
230
|
version: 0.7.2
|
166
|
-
type: :development
|
167
231
|
prerelease: false
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
232
|
+
name: webrat
|
233
|
+
type: :development
|
234
|
+
version_requirements: *id014
|
235
|
+
- !ruby/object:Gem::Dependency
|
236
|
+
requirement: &id015 !ruby/object:Gem::Requirement
|
172
237
|
none: false
|
173
|
-
requirements:
|
174
|
-
- -
|
175
|
-
- !ruby/object:Gem::Version
|
238
|
+
requirements:
|
239
|
+
- - ">="
|
240
|
+
- !ruby/object:Gem::Version
|
241
|
+
hash: 3
|
242
|
+
segments:
|
243
|
+
- 1
|
244
|
+
- 5
|
245
|
+
- 0
|
176
246
|
version: 1.5.0
|
177
|
-
type: :development
|
178
247
|
prerelease: false
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
248
|
+
name: geokit
|
249
|
+
type: :development
|
250
|
+
version_requirements: *id015
|
251
|
+
- !ruby/object:Gem::Dependency
|
252
|
+
requirement: &id016 !ruby/object:Gem::Requirement
|
183
253
|
none: false
|
184
|
-
requirements:
|
185
|
-
- -
|
186
|
-
- !ruby/object:Gem::Version
|
254
|
+
requirements:
|
255
|
+
- - ">="
|
256
|
+
- !ruby/object:Gem::Version
|
257
|
+
hash: 31
|
258
|
+
segments:
|
259
|
+
- 1
|
260
|
+
- 3
|
261
|
+
- 2
|
187
262
|
version: 1.3.2
|
188
|
-
type: :development
|
189
263
|
prerelease: false
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
264
|
+
name: sqlite3-ruby
|
265
|
+
type: :development
|
266
|
+
version_requirements: *id016
|
267
|
+
- !ruby/object:Gem::Dependency
|
268
|
+
requirement: &id017 !ruby/object:Gem::Requirement
|
194
269
|
none: false
|
195
|
-
requirements:
|
196
|
-
- -
|
197
|
-
- !ruby/object:Gem::Version
|
270
|
+
requirements:
|
271
|
+
- - ">="
|
272
|
+
- !ruby/object:Gem::Version
|
273
|
+
hash: 57
|
274
|
+
segments:
|
275
|
+
- 0
|
276
|
+
- 8
|
277
|
+
- 3
|
198
278
|
version: 0.8.3
|
199
|
-
type: :development
|
200
279
|
prerelease: false
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
280
|
+
name: hpricot
|
281
|
+
type: :development
|
282
|
+
version_requirements: *id017
|
283
|
+
- !ruby/object:Gem::Dependency
|
284
|
+
requirement: &id018 !ruby/object:Gem::Requirement
|
205
285
|
none: false
|
206
|
-
requirements:
|
207
|
-
- -
|
208
|
-
- !ruby/object:Gem::Version
|
286
|
+
requirements:
|
287
|
+
- - ">="
|
288
|
+
- !ruby/object:Gem::Version
|
289
|
+
hash: 21
|
290
|
+
segments:
|
291
|
+
- 1
|
292
|
+
- 2
|
293
|
+
- 5
|
209
294
|
version: 1.2.5
|
210
|
-
type: :development
|
211
295
|
prerelease: false
|
212
|
-
|
296
|
+
name: git
|
297
|
+
type: :development
|
298
|
+
version_requirements: *id018
|
213
299
|
description: A Rails plugin for Japanese mobile-phones
|
214
300
|
email: dara@shidara.net
|
215
301
|
executables: []
|
302
|
+
|
216
303
|
extensions: []
|
217
|
-
|
304
|
+
|
305
|
+
extra_rdoc_files:
|
218
306
|
- README
|
219
307
|
- README.rdoc
|
220
|
-
files:
|
308
|
+
files:
|
221
309
|
- .rspec
|
222
310
|
- CHANGELOG
|
223
311
|
- Gemfile
|
@@ -251,13 +339,16 @@ files:
|
|
251
339
|
- lib/jpmobile/mailer.rb
|
252
340
|
- lib/jpmobile/mobile/abstract_mobile.rb
|
253
341
|
- lib/jpmobile/mobile/android.rb
|
342
|
+
- lib/jpmobile/mobile/android_tablet.rb
|
254
343
|
- lib/jpmobile/mobile/au.rb
|
255
344
|
- lib/jpmobile/mobile/ddipocket.rb
|
256
345
|
- lib/jpmobile/mobile/docomo.rb
|
257
346
|
- lib/jpmobile/mobile/emobile.rb
|
347
|
+
- lib/jpmobile/mobile/ipad.rb
|
258
348
|
- lib/jpmobile/mobile/iphone.rb
|
259
349
|
- lib/jpmobile/mobile/smart_phone.rb
|
260
350
|
- lib/jpmobile/mobile/softbank.rb
|
351
|
+
- lib/jpmobile/mobile/tablet.rb
|
261
352
|
- lib/jpmobile/mobile/vodafone.rb
|
262
353
|
- lib/jpmobile/mobile/willcom.rb
|
263
354
|
- lib/jpmobile/mobile/windows_phone.rb
|
@@ -384,6 +475,12 @@ files:
|
|
384
475
|
- test/rails/overrides/app/views/template_path/partial.html.erb
|
385
476
|
- test/rails/overrides/app/views/template_path/show_mobile.html.erb
|
386
477
|
- test/rails/overrides/app/views/template_path/show_mobile_docomo.html.erb
|
478
|
+
- test/rails/overrides/app/views/template_path/smart_phone_only.html.erb
|
479
|
+
- test/rails/overrides/app/views/template_path/smart_phone_only_smart_phone.html.erb
|
480
|
+
- test/rails/overrides/app/views/template_path/with_ipd.html.erb
|
481
|
+
- test/rails/overrides/app/views/template_path/with_ipd_tablet_ipad.html.erb
|
482
|
+
- test/rails/overrides/app/views/template_path/with_tblt.html.erb
|
483
|
+
- test/rails/overrides/app/views/template_path/with_tblt_tablet.html.erb
|
387
484
|
- test/rails/overrides/autotest/discover.rb
|
388
485
|
- test/rails/overrides/config/initializers/jpmobile_generator.rb
|
389
486
|
- test/rails/overrides/config/routes.rb
|
@@ -434,26 +531,36 @@ files:
|
|
434
531
|
- tools/list_gps_unsupported_au.rb
|
435
532
|
homepage: http://jpmobile-rails.org
|
436
533
|
licenses: []
|
534
|
+
|
437
535
|
post_install_message:
|
438
536
|
rdoc_options: []
|
439
|
-
|
537
|
+
|
538
|
+
require_paths:
|
440
539
|
- lib
|
441
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
540
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
442
541
|
none: false
|
443
|
-
requirements:
|
444
|
-
- -
|
445
|
-
- !ruby/object:Gem::Version
|
446
|
-
|
447
|
-
|
542
|
+
requirements:
|
543
|
+
- - ">="
|
544
|
+
- !ruby/object:Gem::Version
|
545
|
+
hash: 3
|
546
|
+
segments:
|
547
|
+
- 0
|
548
|
+
version: "0"
|
549
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
448
550
|
none: false
|
449
|
-
requirements:
|
450
|
-
- -
|
451
|
-
- !ruby/object:Gem::Version
|
452
|
-
|
551
|
+
requirements:
|
552
|
+
- - ">="
|
553
|
+
- !ruby/object:Gem::Version
|
554
|
+
hash: 3
|
555
|
+
segments:
|
556
|
+
- 0
|
557
|
+
version: "0"
|
453
558
|
requirements: []
|
559
|
+
|
454
560
|
rubyforge_project:
|
455
|
-
rubygems_version: 1.8.
|
561
|
+
rubygems_version: 1.8.24
|
456
562
|
signing_key:
|
457
563
|
specification_version: 3
|
458
564
|
summary: A Rails plugin for Japanese mobile-phones
|
459
565
|
test_files: []
|
566
|
+
|