Results 1 to 2 of 2

Thread: Preventing view popping in navigation view in ExtJS modern

  1. #1
    Sencha User
    Join Date
    Dec 2007
    Location
    Budapest, Hungary
    Posts
    132

    Default Preventing view popping in navigation view in ExtJS modern

    Hi,

    I am using the modern framework and I would like to prevent the current view from popping when the back button is pressed. This is mainly to show the user a confirmation dialog when they modified something and not saved it and pushed the back button (either on the device or on the top of the navigation view).
    I have tried two methods:
    1. First the pop event of the navigation view with returning false This is obviously not working because it is not the beforepop event (which does not exist)
    2. Then tried the beforeactiveitemchange event. This works more or less, the only issue is that if I prevent the active item from changing (i.e. popping the view), the titlebar still seems to change back to the previous view, so after a few prevented pops the back button disappears even though the user is still deep down somewhere in the view structure


    So do you have any more ideas on that?
    Thanks

  2. #2
    Sencha User
    Join Date
    Dec 2007
    Location
    Budapest, Hungary
    Posts
    132

    Default

    It turns out that beforeactiveitemchange doesn't work either, because it not only fires when the view is popped, it also fires when another view is pushed into the main view, but in the latter case I don't need the check. I haven't thought of this...
    So anyway, I'm completely stuck on this for now

Posting Permissions

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