This is a migrated thread and some comments may be shown as answers.

Back button handling in Kendo UI mobile

5 Answers 555 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Jan-Dirk
Top achievements
Rank 1
Jan-Dirk asked on 24 May 2013, 08:20 AM
If you built an app that uses the Kendo UI mobile tabstrip then you will notice that if you browse through a few pages by clicking the icons and then use the back button, you will go through all these pages again (in reverse order) until you reach the first page.

For most apps this might not be how you want your app to behave. Most of my apps only respond to the back button if they are on a page that is a sub page of a page that is on the tabstrip. Clicking the back button on a page that is in the tabstrip will popup a question asking if you want to exit the app.

I am wondering if this is the preferred way to do it or does Kendo UI mobile have functionality to behave as I described above. I have not been able to find it.

5 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 24 May 2013, 10:54 AM
Hello Jan-Dirk,

Your request makes sense but it is currently not supported. Just to verify, you're referring to the kind of functionality described in this Kendo UI forum post? If not, can you please elaborate a bit more what is your expected behavior of back button (also assuming your concern is for Android).

Regards,
Steve
Telerik

Don't miss the Icenium May Release Keynote - sign up now!
Share feedback and vote for features on our Feedback Portal.
0
Jan-Dirk
Top achievements
Rank 1
answered on 24 May 2013, 11:16 AM
Hi Steve,

No, my request is different from what is describe by the topic start of the post your refer to.

I will try to explain the functionality I am looking for a little better. Suppose I have a tabstrip with 3 pages.  Page A, B and C. Page C is an info page and doesn't have sub pages, but Page A and B have a button (or listview) to navigate to a sub page (view) of page A (A-sub) and B (B-sub).

Desired behaviour (IMHO):
Example 1:
When I start the App, it will always show page A. I can click on the Icon for page B to navigate to page B and then click page C to navigate to page C. Now (when I am still on page C) I click the back-button, the app navigates back to page B and when I click the back-button again, I will then navigate from page B to page A. In my example (and in the apps I so far have been working on), I consider the tabs (pages) on the tablist as a menu and when I click the back button I don't want to go to a previous visited page, but I want to exit (with or without warning) the app.

Example 2:
Now I start again, still on page A of course. On page A I have a button that navigates me to a sub page (A-sub). I click the button and the sub-page shows. When I click the back button I want me app to navigate back to page A from sub-A. When I click the back button on page A again, I want to leave the app.

Example 3:
Start the App and page A shows. I click the tab to navigate to page B. On page B there is a list with product categories. I click one of the categories which makes me go to B-sub where the products for that category are shown. Clicking the back button would bring me back to page B. Another back-click would allow me to exit the app.

Example 4 (the last one):
Start the App and page A shows. I click the tab to navigate to page B. On page B there is a list with product categories. I click one of the categories which makes me go to B-sub where the products for that category are shown. Now I click the tab for page A, which makes me navigate to page A. Clicking the back-button this time would ask me to exit the App.

In short: I see the pages belonging to the pages on the tabstrip as parent pages. When one of these pages is currently shown, the back button should close the app. No matter what previous navigation you have done. When on a child  page (navigated from a parent page) and clicking the back-button (either hardware or software) will make you go back to it's parent page.

Of course, others might have a different view on this, I would love to hear your consideration then.
0
Steve
Telerik team
answered on 24 May 2013, 11:55 AM
Hi Jan-Dirk,

Thank you for the thorough explanation.

We believe that the request from the forum thread we pointed you to is exactly the same with the only difference the user there talks about the history navigation between different panes/view in the TabStrip, while you involve what action should be done when the history ends. As mentioned in that thread, currently the history is one for the whole application (pane) and the tabs cannot maintain its own stack of views for a history to be kept and what to do when it ends.

As you see, the Kendo UI guys also believe that this functionality makes sense, but would be a huge breaking change for the TabStrip widget. As suggested, it would be best to submit your vision on this functionality as a feature request at KendoUI UserVoice portal, so that other users will be able to vote for it.

Regards,
Steve
Telerik

Don't miss the Icenium May Release Keynote - sign up now!
Share feedback and vote for features on our Feedback Portal.
0
Jan-Dirk
Top achievements
Rank 1
answered on 24 May 2013, 12:04 PM
Yes, I realize that this will break a lot of currently nicely workin apps.

Thank you for your suggestion to post this to the Kendo UserVoice portal. I just did that by copy/pasting me previous message there: http://feedback.kendoui.com/forums/127393-kendo-ui-feedback/suggestions/3992953-different-behaviour-of-kendo-ui-mobile-tabstrip-vi
0
Simon
Top achievements
Rank 1
answered on 08 Nov 2013, 02:38 PM
I wonder if the suggestions in this blog apply.
http://codingwithspike.wordpress.com/2012/12/31/kendo-mobile-gotchas-tips-tricks/
apparently you can manipulate the navigation history object as you like,
Tags
General Discussions
Asked by
Jan-Dirk
Top achievements
Rank 1
Answers by
Steve
Telerik team
Jan-Dirk
Top achievements
Rank 1
Simon
Top achievements
Rank 1
Share this question
or