2

希望以某种方式停止此功能“使用gps”

private void localizacion() {
    progressDialog = ProgressDialog.show(
            actUsarGPS.this, "Por favor espere", "BUSCANDO", true);


     handler = new Handler();

    final Runnable runInUIThread = new Runnable() {
         public void run() {

    LocationManager mlocManager = (LocationManager)getSystemService(Context.LOCATION_SERVICE);
    LocationListener mlocListener = new MyLocationListener();
    mlocManager.requestLocationUpdates( LocationManager.GPS_PROVIDER, 0, 0, mlocListener);

         }
    };

    new Thread() {
         @Override
         public void run() {
            //handler.post(runInUIThread);
            handler.postDelayed(runInUIThread,1000);
            }
        }.start();
}

该对话框有一个取消按钮或后退按钮

并试图阻止他,但无济于事。agradecere 他们很多..

问候

4

0 回答 0