Recollection
Recollection
  • 发布:2016-11-29 10:53
  • 更新:2016-11-29 10:58
  • 阅读:1300

【报bug】getCurrentPosition 锁了屏后一直报No location providers available.错误

分类:HTML5+

就算是在解开锁屏也一直报这个错误 android 红米2a

2016-11-29 10:53 负责人:无 分享
已邀请:
Recollection

Recollection (作者)

应该是在切到后台后 就会这样 我用的是setInterval(function(){
plus.geolocation.getCurrentPosition(function(p){
setAdr1(p);
},function(e){
console.log("监听位置变化信息失败:" + e.message);
},{
geocode:false,
timeout:10000
})
},10000);

Recollection

Recollection (作者)

用wid=plus.geolocation.watchPosition(function(p) {

                            getday();  
                            setAdr1(p);  
                        }, function(e) {  
                            console.log("监听位置变化信息失败:" + e.message);  
                        },{  
                            geocode:false,  
                            maximumAge:10000,  
                            enableHighAccuracy:true  
                        }); 没过多久就会不定位了
  • Recollection (作者)

    plus.geolocation.watchPosition android 锁屏后就不执行了

    2016-11-29 11:06

该问题目前已经被锁定, 无法添加新回复