Results 1 to 3 of 3

Thread: Canceling callbacks

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Sencha User
    Join Date
    Sep 2011
    San Mateo, CA, USA
    Vote Rating

    Default Answered: Canceling callbacks

    I have a ST 2.1 application that is set up so that each page/section has its content loaded asynchronously from a store on initialization. I also have routes set up so that each page is accessible via URL, and the phone's back button can be used to navigate.

    The issue I'm seeing is that if the user navigates to a new page, its content will begin to load, but if the user clicks the "back" button on their phone, it'll navigate to the previous view per my app's route function, but the load callback I had continues to survive, and will execute once the load completes.

    Is there any way to cancel all currently active loads and their callbacks? I'd like to have some action that goes into each route function which cancels any loads that may be taking place. Each page is linked to a number of other pages, so I can't go and individually handle all the combinations very easily.

    Any help would be appreciated!

  2. If you are using Ext.Ajax, it has an abort method that you can pass the request you want to abort.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts