corn_starch 1.8.14 → 1.8.15
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 62cf72ba8d4305c23eddabff203a5f4e3bd0df64
|
4
|
+
data.tar.gz: 130ad797a47daf8961879e1e27f8183866f6bf34
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c1b5ab4a3c4579c54d71798ddc7df329976362e75b1f618592af7016399144ab984f3213d2476112ee8e63f238b5167f7108810630045293a9cf7aed0322cc71
|
7
|
+
data.tar.gz: 211d86440857289097fea369ee8b166f0658c363f6ef159c027008465aff2dd7bc8443b32591355ac970820b36bf966db9743e282d5687f50fbc4d60c85ec114
|
@@ -5,7 +5,8 @@
|
|
5
5
|
|
6
6
|
# Should Element Reload
|
7
7
|
window.infiniscroll_should_reload = (container) ->
|
8
|
-
|
8
|
+
if container.attr('infiniscroll-control') == 'window' then e = $(window) else e = c[0]
|
9
|
+
(e.scrollTop + e.offsetHeight) >= (e.scrollHeight - container.attr('infiniscroll-margin'))
|
9
10
|
|
10
11
|
# InfiniScroll
|
11
12
|
window.infiniscroll = (container) ->
|
@@ -72,7 +73,7 @@ window.infiniscroll_reset = (container) ->
|
|
72
73
|
window.infiniscroll_handler = (c) ->
|
73
74
|
|
74
75
|
# DEBUG
|
75
|
-
alert("infiniscroll_handler -> #{c.id}")
|
76
|
+
alert("infiniscroll_handler -> #{c[0].id}")
|
76
77
|
|
77
78
|
# Check Position
|
78
79
|
if infiniscroll_should_reload c
|
@@ -94,10 +95,6 @@ window.infiniscroll_init = ->
|
|
94
95
|
|
95
96
|
# Acquire
|
96
97
|
c = $(@)
|
97
|
-
|
98
|
-
# DEBUG
|
99
|
-
alert "CONTAINER[0] : #{c[0].id}"
|
100
|
-
alert "CONTAINER : #{c.id}"
|
101
98
|
|
102
99
|
# Unbind Shit
|
103
100
|
c.unbind 'scroll'
|
@@ -105,15 +102,11 @@ window.infiniscroll_init = ->
|
|
105
102
|
# Check Scroll
|
106
103
|
if infiniscroll_should_reload c
|
107
104
|
|
108
|
-
# DEBUG
|
109
|
-
alert("infiniscroll_init -> #{c.id}")
|
110
|
-
|
111
105
|
# Scroll it, bitch !
|
112
|
-
infiniscroll c.id
|
106
|
+
infiniscroll c[0].id
|
113
107
|
|
114
108
|
# Handle Scroll Events
|
115
109
|
c.scroll infiniscroll_handler
|
116
110
|
|
117
111
|
# Initialize InfiniScroll for the Page
|
118
|
-
$(document).on 'page:load', infiniscroll_init
|
119
112
|
$(document).ready infiniscroll_init
|
data/lib/corn_starch/version.rb
CHANGED