jpmobile 1.0.8 → 1.0.9
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -1
- data/VERSION.yml +1 -1
- data/jpmobile.gemspec +1 -1
- data/lib/jpmobile.rb +6 -1
- data/lib/jpmobile/mail.rb +13 -2
- 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/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 +134 -37
data/Rakefile
CHANGED
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 = "1.0.
|
8
|
+
s.version = "1.0.9"
|
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
|
data/lib/jpmobile/mail.rb
CHANGED
@@ -67,7 +67,16 @@ module Mail
|
|
67
67
|
self.body.charset = @charset
|
68
68
|
self.body.mobile = @mobile
|
69
69
|
self.header['Content-Transfer-Encoding'] = @mobile.content_transfer_encoding(self.header)
|
70
|
-
|
70
|
+
if @mobile.decorated?
|
71
|
+
unless self.content_type.match(/image\//)
|
72
|
+
self.header['Content-ID'] = nil
|
73
|
+
end
|
74
|
+
|
75
|
+
unless self.header['Content-Type'].sub_type == 'mixed'
|
76
|
+
self.header['Date'] = nil
|
77
|
+
self.header['Mime-Version'] = nil
|
78
|
+
end
|
79
|
+
end
|
71
80
|
|
72
81
|
buffer = header.encoded
|
73
82
|
buffer << "\r\n"
|
@@ -173,7 +182,9 @@ module Mail
|
|
173
182
|
attached_files = []
|
174
183
|
attachments.each do |p|
|
175
184
|
if p.content_type.match(/^image\//) and p.content_disposition.match(/^inline/)
|
176
|
-
p.header['Content-
|
185
|
+
if p.header['Content-Type'].parameters['filename']
|
186
|
+
p.header['Content-Type'].parameters['name'] = p.header['Content-Type'].parameters['filename'].to_s
|
187
|
+
end
|
177
188
|
inline_images << p
|
178
189
|
elsif p.content_disposition
|
179
190
|
attached_files << p
|
@@ -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)
|
@@ -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,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jpmobile
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.9
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,11 +10,11 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2012-05-16 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: jeweler
|
17
|
-
requirement:
|
17
|
+
requirement: !ruby/object:Gem::Requirement
|
18
18
|
none: false
|
19
19
|
requirements:
|
20
20
|
- - ! '>='
|
@@ -22,10 +22,15 @@ dependencies:
|
|
22
22
|
version: '0'
|
23
23
|
type: :development
|
24
24
|
prerelease: false
|
25
|
-
version_requirements:
|
25
|
+
version_requirements: !ruby/object:Gem::Requirement
|
26
|
+
none: false
|
27
|
+
requirements:
|
28
|
+
- - ! '>='
|
29
|
+
- !ruby/object:Gem::Version
|
30
|
+
version: '0'
|
26
31
|
- !ruby/object:Gem::Dependency
|
27
32
|
name: rails
|
28
|
-
requirement:
|
33
|
+
requirement: !ruby/object:Gem::Requirement
|
29
34
|
none: false
|
30
35
|
requirements:
|
31
36
|
- - ~>
|
@@ -33,10 +38,15 @@ dependencies:
|
|
33
38
|
version: 3.0.10
|
34
39
|
type: :development
|
35
40
|
prerelease: false
|
36
|
-
version_requirements:
|
41
|
+
version_requirements: !ruby/object:Gem::Requirement
|
42
|
+
none: false
|
43
|
+
requirements:
|
44
|
+
- - ~>
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: 3.0.10
|
37
47
|
- !ruby/object:Gem::Dependency
|
38
48
|
name: rspec
|
39
|
-
requirement:
|
49
|
+
requirement: !ruby/object:Gem::Requirement
|
40
50
|
none: false
|
41
51
|
requirements:
|
42
52
|
- - ~>
|
@@ -44,10 +54,15 @@ dependencies:
|
|
44
54
|
version: 2.6.0
|
45
55
|
type: :development
|
46
56
|
prerelease: false
|
47
|
-
version_requirements:
|
57
|
+
version_requirements: !ruby/object:Gem::Requirement
|
58
|
+
none: false
|
59
|
+
requirements:
|
60
|
+
- - ~>
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: 2.6.0
|
48
63
|
- !ruby/object:Gem::Dependency
|
49
64
|
name: rspec-rails
|
50
|
-
requirement:
|
65
|
+
requirement: !ruby/object:Gem::Requirement
|
51
66
|
none: false
|
52
67
|
requirements:
|
53
68
|
- - ~>
|
@@ -55,10 +70,15 @@ dependencies:
|
|
55
70
|
version: 2.6.0
|
56
71
|
type: :development
|
57
72
|
prerelease: false
|
58
|
-
version_requirements:
|
73
|
+
version_requirements: !ruby/object:Gem::Requirement
|
74
|
+
none: false
|
75
|
+
requirements:
|
76
|
+
- - ~>
|
77
|
+
- !ruby/object:Gem::Version
|
78
|
+
version: 2.6.0
|
59
79
|
- !ruby/object:Gem::Dependency
|
60
80
|
name: webrat
|
61
|
-
requirement:
|
81
|
+
requirement: !ruby/object:Gem::Requirement
|
62
82
|
none: false
|
63
83
|
requirements:
|
64
84
|
- - ! '>='
|
@@ -66,10 +86,15 @@ dependencies:
|
|
66
86
|
version: '0'
|
67
87
|
type: :development
|
68
88
|
prerelease: false
|
69
|
-
version_requirements:
|
89
|
+
version_requirements: !ruby/object:Gem::Requirement
|
90
|
+
none: false
|
91
|
+
requirements:
|
92
|
+
- - ! '>='
|
93
|
+
- !ruby/object:Gem::Version
|
94
|
+
version: '0'
|
70
95
|
- !ruby/object:Gem::Dependency
|
71
96
|
name: geokit
|
72
|
-
requirement:
|
97
|
+
requirement: !ruby/object:Gem::Requirement
|
73
98
|
none: false
|
74
99
|
requirements:
|
75
100
|
- - ! '>='
|
@@ -77,10 +102,15 @@ dependencies:
|
|
77
102
|
version: '0'
|
78
103
|
type: :development
|
79
104
|
prerelease: false
|
80
|
-
version_requirements:
|
105
|
+
version_requirements: !ruby/object:Gem::Requirement
|
106
|
+
none: false
|
107
|
+
requirements:
|
108
|
+
- - ! '>='
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
81
111
|
- !ruby/object:Gem::Dependency
|
82
112
|
name: sqlite3-ruby
|
83
|
-
requirement:
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
84
114
|
none: false
|
85
115
|
requirements:
|
86
116
|
- - ! '>='
|
@@ -88,10 +118,15 @@ dependencies:
|
|
88
118
|
version: '0'
|
89
119
|
type: :development
|
90
120
|
prerelease: false
|
91
|
-
version_requirements:
|
121
|
+
version_requirements: !ruby/object:Gem::Requirement
|
122
|
+
none: false
|
123
|
+
requirements:
|
124
|
+
- - ! '>='
|
125
|
+
- !ruby/object:Gem::Version
|
126
|
+
version: '0'
|
92
127
|
- !ruby/object:Gem::Dependency
|
93
128
|
name: hpricot
|
94
|
-
requirement:
|
129
|
+
requirement: !ruby/object:Gem::Requirement
|
95
130
|
none: false
|
96
131
|
requirements:
|
97
132
|
- - ! '>='
|
@@ -99,10 +134,15 @@ dependencies:
|
|
99
134
|
version: '0'
|
100
135
|
type: :development
|
101
136
|
prerelease: false
|
102
|
-
version_requirements:
|
137
|
+
version_requirements: !ruby/object:Gem::Requirement
|
138
|
+
none: false
|
139
|
+
requirements:
|
140
|
+
- - ! '>='
|
141
|
+
- !ruby/object:Gem::Version
|
142
|
+
version: '0'
|
103
143
|
- !ruby/object:Gem::Dependency
|
104
144
|
name: jeweler
|
105
|
-
requirement:
|
145
|
+
requirement: !ruby/object:Gem::Requirement
|
106
146
|
none: false
|
107
147
|
requirements:
|
108
148
|
- - ! '>='
|
@@ -110,10 +150,15 @@ dependencies:
|
|
110
150
|
version: 1.5.1
|
111
151
|
type: :development
|
112
152
|
prerelease: false
|
113
|
-
version_requirements:
|
153
|
+
version_requirements: !ruby/object:Gem::Requirement
|
154
|
+
none: false
|
155
|
+
requirements:
|
156
|
+
- - ! '>='
|
157
|
+
- !ruby/object:Gem::Version
|
158
|
+
version: 1.5.1
|
114
159
|
- !ruby/object:Gem::Dependency
|
115
160
|
name: rspec
|
116
|
-
requirement:
|
161
|
+
requirement: !ruby/object:Gem::Requirement
|
117
162
|
none: false
|
118
163
|
requirements:
|
119
164
|
- - ! '>='
|
@@ -121,10 +166,15 @@ dependencies:
|
|
121
166
|
version: 2.3.0
|
122
167
|
type: :development
|
123
168
|
prerelease: false
|
124
|
-
version_requirements:
|
169
|
+
version_requirements: !ruby/object:Gem::Requirement
|
170
|
+
none: false
|
171
|
+
requirements:
|
172
|
+
- - ! '>='
|
173
|
+
- !ruby/object:Gem::Version
|
174
|
+
version: 2.3.0
|
125
175
|
- !ruby/object:Gem::Dependency
|
126
176
|
name: rspec-rails
|
127
|
-
requirement:
|
177
|
+
requirement: !ruby/object:Gem::Requirement
|
128
178
|
none: false
|
129
179
|
requirements:
|
130
180
|
- - ! '>='
|
@@ -132,10 +182,15 @@ dependencies:
|
|
132
182
|
version: 2.3.0
|
133
183
|
type: :development
|
134
184
|
prerelease: false
|
135
|
-
version_requirements:
|
185
|
+
version_requirements: !ruby/object:Gem::Requirement
|
186
|
+
none: false
|
187
|
+
requirements:
|
188
|
+
- - ! '>='
|
189
|
+
- !ruby/object:Gem::Version
|
190
|
+
version: 2.3.0
|
136
191
|
- !ruby/object:Gem::Dependency
|
137
192
|
name: webrat
|
138
|
-
requirement:
|
193
|
+
requirement: !ruby/object:Gem::Requirement
|
139
194
|
none: false
|
140
195
|
requirements:
|
141
196
|
- - ! '>='
|
@@ -143,10 +198,15 @@ dependencies:
|
|
143
198
|
version: 0.7.2
|
144
199
|
type: :development
|
145
200
|
prerelease: false
|
146
|
-
version_requirements:
|
201
|
+
version_requirements: !ruby/object:Gem::Requirement
|
202
|
+
none: false
|
203
|
+
requirements:
|
204
|
+
- - ! '>='
|
205
|
+
- !ruby/object:Gem::Version
|
206
|
+
version: 0.7.2
|
147
207
|
- !ruby/object:Gem::Dependency
|
148
208
|
name: geokit
|
149
|
-
requirement:
|
209
|
+
requirement: !ruby/object:Gem::Requirement
|
150
210
|
none: false
|
151
211
|
requirements:
|
152
212
|
- - ! '>='
|
@@ -154,10 +214,15 @@ dependencies:
|
|
154
214
|
version: 1.5.0
|
155
215
|
type: :development
|
156
216
|
prerelease: false
|
157
|
-
version_requirements:
|
217
|
+
version_requirements: !ruby/object:Gem::Requirement
|
218
|
+
none: false
|
219
|
+
requirements:
|
220
|
+
- - ! '>='
|
221
|
+
- !ruby/object:Gem::Version
|
222
|
+
version: 1.5.0
|
158
223
|
- !ruby/object:Gem::Dependency
|
159
224
|
name: sqlite3-ruby
|
160
|
-
requirement:
|
225
|
+
requirement: !ruby/object:Gem::Requirement
|
161
226
|
none: false
|
162
227
|
requirements:
|
163
228
|
- - ! '>='
|
@@ -165,10 +230,15 @@ dependencies:
|
|
165
230
|
version: 1.3.2
|
166
231
|
type: :development
|
167
232
|
prerelease: false
|
168
|
-
version_requirements:
|
233
|
+
version_requirements: !ruby/object:Gem::Requirement
|
234
|
+
none: false
|
235
|
+
requirements:
|
236
|
+
- - ! '>='
|
237
|
+
- !ruby/object:Gem::Version
|
238
|
+
version: 1.3.2
|
169
239
|
- !ruby/object:Gem::Dependency
|
170
240
|
name: hpricot
|
171
|
-
requirement:
|
241
|
+
requirement: !ruby/object:Gem::Requirement
|
172
242
|
none: false
|
173
243
|
requirements:
|
174
244
|
- - ! '>='
|
@@ -176,10 +246,15 @@ dependencies:
|
|
176
246
|
version: 0.8.3
|
177
247
|
type: :development
|
178
248
|
prerelease: false
|
179
|
-
version_requirements:
|
249
|
+
version_requirements: !ruby/object:Gem::Requirement
|
250
|
+
none: false
|
251
|
+
requirements:
|
252
|
+
- - ! '>='
|
253
|
+
- !ruby/object:Gem::Version
|
254
|
+
version: 0.8.3
|
180
255
|
- !ruby/object:Gem::Dependency
|
181
256
|
name: git
|
182
|
-
requirement:
|
257
|
+
requirement: !ruby/object:Gem::Requirement
|
183
258
|
none: false
|
184
259
|
requirements:
|
185
260
|
- - ! '>='
|
@@ -187,10 +262,15 @@ dependencies:
|
|
187
262
|
version: 1.2.5
|
188
263
|
type: :development
|
189
264
|
prerelease: false
|
190
|
-
version_requirements:
|
265
|
+
version_requirements: !ruby/object:Gem::Requirement
|
266
|
+
none: false
|
267
|
+
requirements:
|
268
|
+
- - ! '>='
|
269
|
+
- !ruby/object:Gem::Version
|
270
|
+
version: 1.2.5
|
191
271
|
- !ruby/object:Gem::Dependency
|
192
272
|
name: rails
|
193
|
-
requirement:
|
273
|
+
requirement: !ruby/object:Gem::Requirement
|
194
274
|
none: false
|
195
275
|
requirements:
|
196
276
|
- - ! '>='
|
@@ -198,7 +278,12 @@ dependencies:
|
|
198
278
|
version: 3.0.3
|
199
279
|
type: :development
|
200
280
|
prerelease: false
|
201
|
-
version_requirements:
|
281
|
+
version_requirements: !ruby/object:Gem::Requirement
|
282
|
+
none: false
|
283
|
+
requirements:
|
284
|
+
- - ! '>='
|
285
|
+
- !ruby/object:Gem::Version
|
286
|
+
version: 3.0.3
|
202
287
|
description: A Rails plugin for Japanese mobile-phones
|
203
288
|
email: dara@shidara.net
|
204
289
|
executables: []
|
@@ -240,13 +325,16 @@ files:
|
|
240
325
|
- lib/jpmobile/mailer.rb
|
241
326
|
- lib/jpmobile/mobile/abstract_mobile.rb
|
242
327
|
- lib/jpmobile/mobile/android.rb
|
328
|
+
- lib/jpmobile/mobile/android_tablet.rb
|
243
329
|
- lib/jpmobile/mobile/au.rb
|
244
330
|
- lib/jpmobile/mobile/ddipocket.rb
|
245
331
|
- lib/jpmobile/mobile/docomo.rb
|
246
332
|
- lib/jpmobile/mobile/emobile.rb
|
333
|
+
- lib/jpmobile/mobile/ipad.rb
|
247
334
|
- lib/jpmobile/mobile/iphone.rb
|
248
335
|
- lib/jpmobile/mobile/smart_phone.rb
|
249
336
|
- lib/jpmobile/mobile/softbank.rb
|
337
|
+
- lib/jpmobile/mobile/tablet.rb
|
250
338
|
- lib/jpmobile/mobile/vodafone.rb
|
251
339
|
- lib/jpmobile/mobile/willcom.rb
|
252
340
|
- lib/jpmobile/mobile/windows_phone.rb
|
@@ -371,6 +459,12 @@ files:
|
|
371
459
|
- test/rails/overrides/app/views/template_path/partial.html.erb
|
372
460
|
- test/rails/overrides/app/views/template_path/show_mobile.html.erb
|
373
461
|
- test/rails/overrides/app/views/template_path/show_mobile_docomo.html.erb
|
462
|
+
- test/rails/overrides/app/views/template_path/smart_phone_only.html.erb
|
463
|
+
- test/rails/overrides/app/views/template_path/smart_phone_only_smart_phone.html.erb
|
464
|
+
- test/rails/overrides/app/views/template_path/with_ipd.html.erb
|
465
|
+
- test/rails/overrides/app/views/template_path/with_ipd_tablet_ipad.html.erb
|
466
|
+
- test/rails/overrides/app/views/template_path/with_tblt.html.erb
|
467
|
+
- test/rails/overrides/app/views/template_path/with_tblt_tablet.html.erb
|
374
468
|
- test/rails/overrides/autotest/discover.rb
|
375
469
|
- test/rails/overrides/config/initializers/jpmobile_generator.rb
|
376
470
|
- test/rails/overrides/config/routes.rb
|
@@ -431,6 +525,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
431
525
|
- - ! '>='
|
432
526
|
- !ruby/object:Gem::Version
|
433
527
|
version: '0'
|
528
|
+
segments:
|
529
|
+
- 0
|
530
|
+
hash: 257980358287254125
|
434
531
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
435
532
|
none: false
|
436
533
|
requirements:
|
@@ -439,7 +536,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
439
536
|
version: '0'
|
440
537
|
requirements: []
|
441
538
|
rubyforge_project:
|
442
|
-
rubygems_version: 1.8.
|
539
|
+
rubygems_version: 1.8.24
|
443
540
|
signing_key:
|
444
541
|
specification_version: 3
|
445
542
|
summary: A Rails plugin for Japanese mobile-phones
|