Skip to content

Commit

Permalink
pullToRefreshTrigger
Browse files Browse the repository at this point in the history
  • Loading branch information
nolimits4web committed Aug 1, 2014
1 parent c88701c commit 62c8f2f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/js/pull-to-refresh.js
Original file line number Diff line number Diff line change
Expand Up @@ -111,3 +111,14 @@ app.pullToRefreshDone = function (container) {
container.removeClass('transitioning pull-up');
});
};
app.pullToRefreshTrigger = function (container) {
container = $(container);
if (container.length === 0) container = $('.pull-to-refresh-content');
if (container.hasClass('refreshing')) return;
container.addClass('transitioning refreshing');
container.trigger('refresh', {
done: function () {
app.pullToRefreshDone(container);
}
});
};

0 comments on commit 62c8f2f

Please sign in to comment.