Universal Apps – Settings on stun

Settings are one of those things that are not the same between Windows and the phone. In Windows, there are charms and developer can add their code to Charms like Settings, on the phone, the developer has to handle it on a page they create that they call by adding a button to the screen, usually an AppBar button. So, the user has a nice UI experience on the phone and the developer has to match the experience on the phone. Normally this is done with the AppBar. There are also several other housekeeping tasks, (help, about, reviews, promos for your other apps) that also compete for the AppBar.  On my WP7 apps, with only four AppBar buttons, I had to make use of the AppBar menu buttons as well. To allow multilingual text on the buttons, this was done in code behind and got a bit messy.

Now with Universal Apps, a method is needed to try and reuse some of the code. So, rather than managing multiple buttons, it was easier to use a single button and make the page called a bit smarter. The logical choice appeared to make the “Settings” page a Panorama or a Pivot page with each housekeeping task having their own subpage. Since Panorama has gone and Pivot is on it’s way out, a HubPage appears to be the solution. So a button to get to the page and scrolling left or right to get to the information worked nicely. The overlapping of the hub sections gives a nice hint at the next hub section.

Of course, there is still the issue with duplicating the code for Windows and the Phone. This can be easily handled by making each housekeeping task a user control  placed in the shared folder. So the different mechanisms for calling the housekeeping task are stored in the Windows and the Phone folders and the actual functions, that are probably going to evolve over time, are in the Shared Folder.

Windows will use commands to invoke flyouts of the housekeeping tasks, and the Phone will use a HubSection to do the same thing.

Enjoy.

John Marshall… Visio MVP       Visio.MVPs.org

Published by johnvisiomvp

The original Visio MVP. I have worked with the Visio team since 1993