Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

back button on simulator in companion app.

Hi, i'm new in javascript and developing fitbit app. I'm trying to code my app with companion and setting in it. The main problem is when i launch it, the phone simulator starts, but the back button at the left top doesnt work at all. Is it a fake button or there is a way to add an event on it?

thanks for the answers.

Best Answer
0 Votes
2 REPLIES 2

Typically all changes are saved as they are changed by the user, the button doesn't do anything and there isn't an unload event.

 

What are you actually trying to acheive with this?

Best Answer
0 Votes

Thanks for the answer!

Basically what i would like to do is to create more than one setting page. i'd like to have one main page with buttons that open others specific setting pages. The solution i found, by now, is to create more than one function in index.jsx, each one with his page to display and i added events on buttons that load specific pages.

Something like this:

 

registerSettingsPage(showMainPage); //this load at the beginning
 
//these functions are attached to the 3 buttons i have
function sensor() { 
registerSettingsPage(showSensorsPage);
}

function data() {
registerSettingsPage(showDataPage);
}

function setting() {
registerSettingsPage(showSettingsPage);
}

 

i think this probably isn't the best solution.

Thanks in advance!

Best Answer
0 Votes