Skip to content

Commit

Permalink
update demo
Browse files Browse the repository at this point in the history
demo增加退出功能
  • Loading branch information
jguang committed Jun 16, 2014
1 parent 7e5e5fd commit 5d4f145
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions demo/www/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,14 @@
});
});

//返回键退出应用
var layerApi = main.api.layer;
layerApi.on("backPressedBeforeExit",function(){
if(window.confirm("确定要退出吗?")){
layerApi.destroy();
}
});

})(Blend,Blend.Layer,Blend.LayerGroup);
</script>
</body>
Expand Down

0 comments on commit 5d4f145

Please sign in to comment.