redpotion 1.6.0 → 1.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +8 -6
- data/lib/project/pro_motion/data_table_search_delegate.rb +10 -6
- data/lib/project/pro_motion/data_table_searchable.rb +9 -10
- data/lib/project/pro_motion/table.rb +1 -4
- data/lib/project/ruby_motion_query/app.rb +1 -1
- data/lib/project/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cad66fd5955beb96e1219c687d6a684262efda98
|
4
|
+
data.tar.gz: 5fe84c7e241010423f97747bae4019bd841cd79d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5ca216b7c682621fb3c9bce5bcf6009b23025fa3bfa684786c079d86c7eb07148a01062831e21e90481f6ce73aca2474a5e9e20cbe633507a1bb19dd22c03346
|
7
|
+
data.tar.gz: 60668cec1b2348827c94a5610fb106d3792868951d08f8e3498d121d814f7d4b7b6054633e8a45540600eec4d1b72c05075e09e31cf3767d3bfbe77c37b92bb9
|
data/README.md
CHANGED
@@ -2,9 +2,8 @@
|
|
2
2
|
|
3
3
|
<br />
|
4
4
|
|
5
|
-
[![
|
6
|
-
[![Build Status](https://
|
7
|
-
[![Gem Version](https://badge.fury.io/rb/redpotion.png)](http://badge.fury.io/rb/redpotion)
|
5
|
+
[![Gem Version](https://img.shields.io/gem/v/redpotion.svg?style=flat)](https://rubygems.org/gems/redpotion)
|
6
|
+
[![Build Status](https://img.shields.io/travis/infinitered/redpotion.svg?style=flat)](https://travis-ci.org/infinitered/redpotion)
|
8
7
|
|
9
8
|
# RedPotion
|
10
9
|
|
@@ -23,11 +22,14 @@ ProMotion for screens and RMQ for styles, animations, traversing, events, etc.
|
|
23
22
|
|
24
23
|
----------
|
25
24
|
|
26
|
-
<br />
|
27
25
|
<br />
|
28
26
|
|
29
27
|
[![image](http://ir_wp.s3.amazonaws.com/wp-content/uploads/sites/19/2015/04/rp_docs.png)](http://docs.redpotion.org)
|
30
28
|
|
31
|
-
**Read the [RedPotion Documentation](http://docs.redpotion.org)
|
29
|
+
**Read the [RedPotion Documentation](http://docs.redpotion.org).**
|
30
|
+
|
31
|
+
**Read the [RedPotion Quick Start Documentation](http://docs.redpotion.org/en/latest/quick_start/).**
|
32
|
+
|
33
|
+
## Premium Support
|
32
34
|
|
33
|
-
|
35
|
+
[RedPotion](https://github.com/infinitered/redpotion), as an open source project, is free to use and always will be. [Infinite Red](https://infinite.red/) offers premium RedPotion support and general mobile app design/development services. Email us at [hello@infinite.red](mailto:hello@infinite.red) to get in touch with us for more details.
|
@@ -1,15 +1,19 @@
|
|
1
1
|
class DataTableSeachDelegate
|
2
2
|
attr_accessor :parent
|
3
3
|
|
4
|
-
|
5
|
-
|
4
|
+
# UISearchControllerDelegate methods
|
5
|
+
|
6
|
+
def willPresentSearchController(search_controller)
|
7
|
+
parent.dt_searchDisplayControllerWillBeginSearch(search_controller)
|
6
8
|
end
|
7
9
|
|
8
|
-
def
|
9
|
-
parent.dt_searchDisplayControllerWillEndSearch(
|
10
|
+
def willDismissSearchController(search_controller)
|
11
|
+
parent.dt_searchDisplayControllerWillEndSearch(search_controller)
|
10
12
|
end
|
11
13
|
|
12
|
-
|
13
|
-
|
14
|
+
# UISearchResultsUpdating protocol method
|
15
|
+
def updateSearchResultsForSearchController(search_controller)
|
16
|
+
search_string = search_controller.searchBar.text
|
17
|
+
parent.dt_searchDisplayController(search_controller, shouldReloadTableForSearchString: search_string) if @_data_table_searching
|
14
18
|
end
|
15
19
|
end
|
@@ -9,6 +9,7 @@ module ProMotion
|
|
9
9
|
@data_table_predicate_fields = params[:search_bar][:fields]
|
10
10
|
end
|
11
11
|
params[:delegate] = search_delegate
|
12
|
+
params[:search_results_updater] = search_delegate
|
12
13
|
|
13
14
|
make_searchable(params)
|
14
15
|
end
|
@@ -59,10 +60,9 @@ module ProMotion
|
|
59
60
|
|
60
61
|
######### iOS methods, headless camel case #######
|
61
62
|
|
62
|
-
def
|
63
|
-
@
|
64
|
-
|
65
|
-
true
|
63
|
+
def dt_searchDisplayControllerWillBeginSearch(controller)
|
64
|
+
@_data_table_searching = true
|
65
|
+
search_controller.delegate.will_begin_search if search_controller.delegate.respond_to? "will_begin_search"
|
66
66
|
end
|
67
67
|
|
68
68
|
def dt_searchDisplayControllerWillEndSearch(controller)
|
@@ -70,15 +70,14 @@ module ProMotion
|
|
70
70
|
@_search_fetch_controller.delegate = nil unless @_search_fetch_controller.nil?
|
71
71
|
@_search_fetch_controller = nil
|
72
72
|
@_data_table_search_string = nil
|
73
|
-
|
74
|
-
@table_search_display_controller.delegate.will_end_search if @table_search_display_controller.delegate.respond_to? "will_end_search"
|
73
|
+
search_controller.delegate.will_end_search if search_controller.delegate.respond_to? "will_end_search"
|
75
74
|
update_table_data
|
76
75
|
end
|
77
76
|
|
78
|
-
def
|
79
|
-
@
|
80
|
-
|
81
|
-
|
77
|
+
def dt_searchDisplayController(controller, shouldReloadTableForSearchString:search_string)
|
78
|
+
@_data_table_search_string = search_string
|
79
|
+
reset_search_frc
|
80
|
+
true
|
82
81
|
end
|
83
82
|
|
84
83
|
end
|
@@ -15,10 +15,7 @@ module ProMotion
|
|
15
15
|
if self.is_a?(ProMotion::DataTableScreen)
|
16
16
|
self.make_data_table_searchable(content_controller: self, search_bar: self.class.get_searchable_params)
|
17
17
|
else
|
18
|
-
self.make_searchable(
|
19
|
-
end
|
20
|
-
if self.class.get_searchable_params[:hide_initially]
|
21
|
-
self.tableView.contentOffset = CGPointMake(0, self.searchDisplayController.searchBar.frame.size.height)
|
18
|
+
self.make_searchable(self.class.get_searchable_params)
|
22
19
|
end
|
23
20
|
end
|
24
21
|
end
|
@@ -19,7 +19,7 @@ module RubyMotionQuery
|
|
19
19
|
image_cache.clearDisk
|
20
20
|
else
|
21
21
|
# Support for SDWebImage v4.x
|
22
|
-
image_cache.
|
22
|
+
image_cache.deleteOldFiles
|
23
23
|
end
|
24
24
|
else
|
25
25
|
puts "\n[RedPotion ERROR] tried to reset image cache without SDWebImage cocoapod. Please add this to your Rakefile: \n\napp.pods do\n pod \"SDWebImage\"\nend\n"
|
data/lib/project/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redpotion
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.7.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Infinite Red
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ruby_motion_query
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 2.
|
33
|
+
version: 2.7.0
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 2.
|
40
|
+
version: 2.7.0
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: motion_print
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -179,7 +179,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
179
179
|
version: '0'
|
180
180
|
requirements: []
|
181
181
|
rubyforge_project:
|
182
|
-
rubygems_version: 2.
|
182
|
+
rubygems_version: 2.6.13
|
183
183
|
signing_key:
|
184
184
|
specification_version: 4
|
185
185
|
summary: RedPotion combines RMQ, ProMotion, CDQ, AFMotion, and more for the perfect
|