Code example for ToneGenerator

Methods: releasestopTone

0
	} 
 
	private void stopBeep() { 
		try { 
			if (tg != null) {
				tg.stopTone();
				tg.release();
				tg = null;
				// Log("stopTone called in stopBeep"); 
			} 
		} catch (Exception e) {
			Log(e.getMessage());
		} 
	} 
 
	private boolean isVitalSignsServiceRunning() { 
		ActivityManager manager = (ActivityManager)getSystemService(ACTIVITY_SERVICE);
		boolean isRunning=false;
		for (RunningServiceInfo service : manager.getRunningServices(Integer.MAX_VALUE)) {
			if ("com.dennis.vitalsigns.VitalSignsService".equals(service.service.getClassName())) {				
				isRunning=true;