Jump to content
Search Community

BKraupa

Members
  • Posts

    3
  • Joined

  • Last visited

Community Answers

  1. BKraupa's post in Pinned sections and resize was marked as the answer   
    Dear Jack,
     
    you pushed me in the right direction. It's not enough to just restore the scroll position, but using the window height to calculate the relative scroll height works as intended.
     
    onRefreshInit: function(self) { self.prevWindowHeight = $(window).height(); self.prevScroll = self.scroll(); }, onRefresh: function(self) { var afterWindowHeight = $(window).height(); self.scroll(self.prevScroll / self.prevWindowHeight * afterWindowHeight); }  
    Many thanks for the help!
×
×
  • Create New...