ib 0.7.2 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/ib/oc_interface.rb +9 -1
- data/lib/ib/version.rb +1 -1
- data/spec/fixtures/common/custom_view.rb +3 -0
- data/spec/lib/ib/generator_spec.rb +2 -0
- data/spec/lib/ib/parser_spec.rb +8 -7
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 01ddefe75de6227317cd67767fd0fcbec6366d9c
|
4
|
+
data.tar.gz: aa05518904d615d4f4a1e7f1278f901e448bf743
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 94fa7770655e48bd2adccdae567002d92b5deda47f6b5cfab5b25b0f46d160080570e1a748e8afd385ca31d7e15ee0ea8f1c7f0643dcc81cfe045c1b72fe9634
|
7
|
+
data.tar.gz: b256e81cfd1d46c228b9e00c195c237da63610ab9a243ac6813be1e81a49f6bc96a7c2d83eae0a3b0450824b0439e1f8b977195781e3053a0dad37ee50176d89
|
data/Gemfile.lock
CHANGED
data/lib/ib/oc_interface.rb
CHANGED
@@ -13,7 +13,15 @@ class IB::OCInterface
|
|
13
13
|
|
14
14
|
class Action < Struct.new(:variable, :arg, :return_type)
|
15
15
|
def to_declare
|
16
|
-
|
16
|
+
if arg
|
17
|
+
if arg =~ /story_?board/i
|
18
|
+
"#{variable}:(UIStoryBoard *) #{arg}"
|
19
|
+
else
|
20
|
+
"#{variable}:(#{return_type ? "#{return_type}*" : 'id'}) #{arg}"
|
21
|
+
end
|
22
|
+
else
|
23
|
+
"#{variable}"
|
24
|
+
end
|
17
25
|
end
|
18
26
|
end
|
19
27
|
|
data/lib/ib/version.rb
CHANGED
@@ -47,6 +47,7 @@ describe IB::Generator do
|
|
47
47
|
-(IBAction) actionWithComment:(id) sender;
|
48
48
|
-(IBAction) actionWithBrackets:(id) sender;
|
49
49
|
-(IBAction) actionWithoutArgs;
|
50
|
+
-(IBAction) exitAction:(UIStoryBoard *) story_board;
|
50
51
|
-(IBAction) actionWithDefaultedArgs:(id) sender;
|
51
52
|
|
52
53
|
@end
|
@@ -108,6 +109,7 @@ OBJC
|
|
108
109
|
-(IBAction) actionWithComment:(id) sender;
|
109
110
|
-(IBAction) actionWithBrackets:(id) sender;
|
110
111
|
-(IBAction) actionWithoutArgs;
|
112
|
+
-(IBAction) exitAction:(UIStoryBoard *) story_board;
|
111
113
|
-(IBAction) actionWithDefaultedArgs:(id) sender;
|
112
114
|
|
113
115
|
@end
|
data/spec/lib/ib/parser_spec.rb
CHANGED
@@ -19,13 +19,14 @@ describe IB::Parser do
|
|
19
19
|
["yellowLabelCollection", "id"]
|
20
20
|
]
|
21
21
|
info[:actions].should == [
|
22
|
-
["someAction", "sender",
|
23
|
-
["segueAction", "sender",
|
24
|
-
["anotherAction", "button",
|
25
|
-
["actionWithComment", "sender",
|
26
|
-
["actionWithBrackets", "sender",
|
27
|
-
["actionWithoutArgs", nil,
|
28
|
-
["
|
22
|
+
["someAction", "sender", nil],
|
23
|
+
["segueAction", "sender", "UIStoryboardSegue"],
|
24
|
+
["anotherAction", "button", nil],
|
25
|
+
["actionWithComment", "sender", nil],
|
26
|
+
["actionWithBrackets", "sender", nil],
|
27
|
+
["actionWithoutArgs", nil, nil],
|
28
|
+
["exitAction", "story_board", nil],
|
29
|
+
["actionWithDefaultedArgs", "sender", nil]
|
29
30
|
]
|
30
31
|
end
|
31
32
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ib
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yury Korolev
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2015-
|
14
|
+
date: 2015-08-03 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: xcodeproj
|
@@ -188,7 +188,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
188
188
|
version: '0'
|
189
189
|
requirements: []
|
190
190
|
rubyforge_project:
|
191
|
-
rubygems_version: 2.
|
191
|
+
rubygems_version: 2.4.5
|
192
192
|
signing_key:
|
193
193
|
specification_version: 4
|
194
194
|
summary: Small portion of love to interface builder with rubymotion
|