ruby_motion_query 0.5.3 → 0.5.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/README.md +2 -2
- data/motion/ext.rb +4 -2
- data/motion/ruby_motion_query/app.rb +3 -1
- data/motion/ruby_motion_query/stylers/ui_scroll_view_styler.rb +8 -1
- data/motion/ruby_motion_query/stylers/ui_table_view_styler.rb +19 -1
- data/motion/ruby_motion_query/stylers/ui_view_styler.rb +5 -0
- data/motion/ruby_motion_query/version.rb +1 -1
- data/templates/table_view_controller/app/controllers/name_controller.rb +1 -1
- data/templates/table_view_controller/app/views/name_cell.rb +0 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
OTg1MDhiZjc4MDZkZjM4NDBmMGQyZTI4MmJkZWYwNjJlOTJjMDQwYw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
MjI2OGY0ZTUzYmUyZmY1OWNhZWIzNThiZWY0OTRjMTEwMDQ2ZmFkMA==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
ZTI0NmFhZWRkOTk4NTg1MGUyMjYyZDdkZjBlZjQwYjMyZDRlN2I3YzBiNGU2
|
10
|
+
YTQ1NDUwYjg3OWE3ZjY4Njk4MDc2OWVmMzQzNzliNzUzMzViZWZhMzVmZmZl
|
11
|
+
OWE5MDU0YzJjYmE4NTY3ZWI0MWZlYTgxZmIxMzIxZDgwOTc3ZTg=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NWZjYzBlNDk4NmY0ZGJjOTQyMDdiMTg4YjZiMWY0YjI5NDVmNzZmNjMwYzhi
|
14
|
+
NDc3YTE0Mzg1NzliNWFkYjQ5YjkzMTI5MDVhZjU1ZTMyYTRlZWVkMTZhNWZl
|
15
|
+
YTNjOWYyNzNiYWUxN2E0ODdhMmJmNzkzZmVhNGQ3NTEzZjRlM2Y=
|
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
![
|
1
|
+
![RMQ logo](https://raw.github.com/infinitered/rmq/master/resources/logo@2x.png?raw=true)
|
2
2
|
|
3
3
|
# RubyMotionQuery - RMQ
|
4
4
|
|
@@ -718,7 +718,7 @@ class MainController < UIViewController
|
|
718
718
|
def viewDidLoad
|
719
719
|
super
|
720
720
|
|
721
|
-
rmq.stylesheet =
|
721
|
+
rmq.stylesheet = MainStyleSheet
|
722
722
|
view.rmq.apply_style :root_view
|
723
723
|
|
724
724
|
@title_label = rmq.append(UILabel, :title_label).get
|
data/motion/ext.rb
CHANGED
@@ -1,7 +1,9 @@
|
|
1
1
|
class Object
|
2
2
|
def rmq(*working_selectors)
|
3
|
-
if
|
4
|
-
|
3
|
+
if (app = RubyMotionQuery::RMQ.app) && (window = app.window) && (cvc = app.current_view_controller)
|
4
|
+
cvc.rmq(working_selectors)
|
5
|
+
else
|
6
|
+
RubyMotionQuery::RMQ.create_with_array_and_selectors([], working_selectors, self)
|
5
7
|
end
|
6
8
|
end
|
7
9
|
end
|
@@ -16,7 +16,9 @@ module RubyMotionQuery
|
|
16
16
|
|
17
17
|
# @return [UIWindow]
|
18
18
|
def window
|
19
|
-
|
19
|
+
if shared_application = UIApplication.sharedApplication
|
20
|
+
shared_application.keyWindow || shared_application.windows[0]
|
21
|
+
end
|
20
22
|
end
|
21
23
|
|
22
24
|
# @return [UIApplicationDelegate]
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module RubyMotionQuery
|
2
2
|
module Stylers
|
3
3
|
|
4
|
-
class UIScrollViewStyler < UIViewStyler
|
4
|
+
class UIScrollViewStyler < UIViewStyler
|
5
5
|
def paging=(value) ; @view.pagingEnabled = value ; end
|
6
6
|
def paging ; @view.isPagingEnabled ; end
|
7
|
+
|
8
|
+
def scroll_enabled=(value) ; @view.scrollEnabled = value ; end
|
9
|
+
def scroll_enabled ; @view.isScrollEnabled ; end
|
10
|
+
|
11
|
+
def direction_lock=(value) ; @view.directionalLockEnabled = value ; end
|
12
|
+
def direction_lock ; @view.isDirectionalLockEnabled ; end
|
13
|
+
|
7
14
|
end
|
8
15
|
|
9
16
|
end
|
@@ -1,7 +1,25 @@
|
|
1
1
|
module RubyMotionQuery
|
2
2
|
module Stylers
|
3
3
|
|
4
|
-
class UITableViewStyler < UIScrollViewStyler
|
4
|
+
class UITableViewStyler < UIScrollViewStyler
|
5
|
+
|
6
|
+
def separator_style=(value)
|
7
|
+
@view.separatorStyle = (SEPARATOR_STYLES[value] || value)
|
8
|
+
end
|
9
|
+
def separator_style ; @view.separatorStyle ; end
|
10
|
+
|
11
|
+
def separator_color=(value) ; @view.separatorColor = value ; end
|
12
|
+
def separator_color ; @view.separatorColor ; end
|
13
|
+
|
14
|
+
def allows_selection=(value) ; @view.allowsSelection = value ; end
|
15
|
+
def allows_selection ; @view.allowsSelection ; end
|
16
|
+
|
17
|
+
SEPARATOR_STYLES = {
|
18
|
+
none: UITableViewCellSeparatorStyleNone,
|
19
|
+
single: UITableViewCellSeparatorStyleSingleLine,
|
20
|
+
etched: UITableViewCellSeparatorStyleSingleLineEtched
|
21
|
+
}
|
22
|
+
|
5
23
|
end
|
6
24
|
|
7
25
|
end
|
@@ -37,7 +37,7 @@ class <%= @name_camel_case %>Controller < UITableViewController
|
|
37
37
|
data_row = @data[index_path.row]
|
38
38
|
|
39
39
|
cell = table_view.dequeueReusableCellWithIdentifier(<%= @name.upcase %>_CELL_ID) || begin
|
40
|
-
rmq.create(<%= @name_camel_case %>Cell).get
|
40
|
+
rmq.create(<%= @name_camel_case %>Cell, :<%= @name %>_cell, reuse_identifier: <%= @name.upcase %>_CELL_ID).get
|
41
41
|
end
|
42
42
|
|
43
43
|
cell.update(data_row)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby_motion_query
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Todd Werth
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-02-
|
12
|
+
date: 2014-02-25 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bacon
|