Last active
December 18, 2015 01:09
-
-
Save mixonic/5701790 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/packages/list-view/lib/list_view_mixin.js b/packages/list-view/lib/list_view_mixin.js | |
index 2148cf9..6b8bb74 100644 | |
--- a/packages/list-view/lib/list_view_mixin.js | |
+++ b/packages/list-view/lib/list_view_mixin.js | |
@@ -214,6 +214,10 @@ Ember.ListViewMixin = Ember.Mixin.create({ | |
endingIndex = min(maxContentIndex, visibleEndingIndex); | |
this.trigger('scrollYChanged', y); | |
+ console.log('start'); | |
+ var el = this.$('.ember-list-scrolling-view') | |
+ if (el) { el.css({position: 'relative'}) } | |
+ this.finishScrollingAfterInactivity(); | |
if (startingIndex === this._lastStartingIndex && | |
endingIndex === this._lastEndingIndex) { | |
@@ -227,6 +231,16 @@ Ember.ListViewMixin = Ember.Mixin.create({ | |
}, this); | |
}, | |
+ finishScrollingAfterInactivity: function(){ | |
+ Em.run.backburner.debounce(this, this.finishScrolling, 250); | |
+ }, | |
+ | |
+ finishScrolling: function(){ | |
+ console.log('finish'); | |
+ var el = this.$('.ember-list-scrolling-view') | |
+ if (el) { el.css({position: ''}) } | |
+ }, | |
+ | |
childViewsWillSync: Ember.K, | |
childViewsDidSync: Ember.K, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment