Package com.google.zxing.client.android
Class BeepManager
- java.lang.Object
-
- com.google.zxing.client.android.BeepManager
-
public final class BeepManager extends Object
Manages beeps and vibrations.
-
-
Constructor Summary
Constructors Constructor Description BeepManager(Activity activity)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisBeepEnabled()booleanisVibrateEnabled()MediaPlayerplayBeepSound()voidplayBeepSoundAndVibrate()voidsetBeepEnabled(boolean beepEnabled)Call updatePrefs() after setting this.voidsetVibrateEnabled(boolean vibrateEnabled)Call updatePrefs() after setting this.
-
-
-
Constructor Detail
-
BeepManager
public BeepManager(Activity activity)
-
-
Method Detail
-
isBeepEnabled
public boolean isBeepEnabled()
-
setBeepEnabled
public void setBeepEnabled(boolean beepEnabled)
Call updatePrefs() after setting this. If the device is in silent mode, it will not beep.- Parameters:
beepEnabled- true to enable beep
-
isVibrateEnabled
public boolean isVibrateEnabled()
-
setVibrateEnabled
public void setVibrateEnabled(boolean vibrateEnabled)
Call updatePrefs() after setting this.- Parameters:
vibrateEnabled- true to enable vibrate
-
playBeepSoundAndVibrate
public void playBeepSoundAndVibrate()
-
playBeepSound
public MediaPlayer playBeepSound()
-
-