public
Created

click on tab workaround for titanium mobile

  • Download Gist
click_tab.js
JavaScript
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
var newPetitionListener = function (e) {
newPetition(win, params);
}
, cameraView = Ti.UI.createView({
width: 95,
height: 50,
bottom: 0
});
cameraView.addEventListener("click", newPetitionListener);
 
win.addEventListener("focus", function (e) {
win.containingTab.tabGroup.add(cameraView);
});
 
win.addEventListener("blur", function (e) {
win.containingTab.tabGroup.remove(cameraView);
});

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.