framework7 icon indicating copy to clipboard operation
framework7 copied to clipboard

destroyPullToRefresh(ptrContent) will dispose all ptr

Open mohshraim opened this issue 9 years ago • 4 comments

This is a (multiple allowed):

  • [x] bug

  • [ ] enhancement

  • Framework7 Version: 1.6.0

  • Platform and Target: IOS, ANDROID, web

i have tow tabs each have its own ptr… when i destroy one, both will be destroyed.. i trace the framework7.js code but really wouldn't like to do changes that iam not quite sure anyway; on lines 6830 if (pullToRefreshContent[0].f7DestroyPullToRefresh) pullToRefreshContent[0].f7DestroyPullToRefresh(); when call f7DestroyPullToRefresh(); it will go to line 6792 eventsTarget.off(app.touchEvents.start, handleTouchStart, passiveListener); and on eventsTarget object i found that contain both ptrContent selector, so the app turn off the touch events and the whole pullToRefresh on all selectors on app…

https://jsfiddle.net/mohshraim/s2n1p730/9/

this test will show the unexpected behavioure i have,,, its not exact the same case... that both tabs have destroy but only tab1 destroy will work!! and when its work its destroy the tab2 also... 1-should try to start by tab1 pull then tab 2 will not work,, 2-and another try start with tab2 then tab 1 but tab 1 still work?!!

thanks for help

mohshraim avatar Apr 25 '17 22:04 mohshraim

i did the required changes to solve the bug and test it on many cases.. should i mention the changes here or do a pull request?.. if yes please guide me which branch shall i do my pull request

mohshraim avatar Apr 27 '17 21:04 mohshraim

should i close this issue as i did the fix code,, or should i wait for my pull request approval??? its 5 days since i submit the fix code!! I need to understand if something wrong on my submitting method,, so i can start contribute for this project... thanks

mohshraim avatar May 02 '17 17:05 mohshraim

Dear @nolimits4web
please review my pull request to fix mentioned issue..

thanks

mohshraim avatar May 10 '17 14:05 mohshraim

Issue is closed because of outdated/irrelevant/not actual

If this issue is still actual and reproducible for latest version of Framework7, please create new issue and fill the issue template correctly:

  • Clearly describe the issue including steps to reproduce when it is a bug.
  • Make sure you fill in the earliest version that you know has the issue.
  • Provide live link or JSFiddle/Codepen or website with issue

nolimits4web avatar Mar 07 '18 14:03 nolimits4web