kopia lustrzana https://github.com/ge0rg/aprsdroid
				
				
				
			SmartBeaconing: do not crash on background start without GPS permission
							rodzic
							
								
									5844a59c75
								
							
						
					
					
						commit
						9a58e4781b
					
				|  | @ -22,8 +22,8 @@ class SmartBeaconing(service : AprsService, prefs : PrefsWrapper) extends Locati | |||
| 				0, 0, this) | ||||
| 			started = true | ||||
| 		} catch { | ||||
| 			case e : IllegalArgumentException => | ||||
| 				// this device does not have GPS. Oops. | ||||
| 			case e @ (_: IllegalArgumentException | _: SecurityException) => | ||||
| 				// we lack GPS or GPS permissions | ||||
| 				service.postAbort(service.getString(R.string.service_sm_no_gps) | ||||
| 					+ "\n" + e.getMessage()) | ||||
| 		} | ||||
|  |  | |||
		Ładowanie…
	
		Reference in New Issue
	
	 Georg Lukas
						Georg Lukas