Stop the ringtone when other seek bar is adjust
- Stop the ringtone when other seek bar is adjust. - Add test to verify when onStartTrackingTouch() is called, will call stopSample(). Bug: 80194851 Test: make -j42 RunSettingsRoboTests Change-Id: I2300f0f56340c3698f62cc911bda7b7a94d23a7a
This commit is contained in:
@@ -138,6 +138,12 @@ public class VolumeSeekBarPreference extends SeekBarPreference {
|
||||
mZenMuted = zenMuted;
|
||||
updateIconView();
|
||||
}
|
||||
@Override
|
||||
public void onStartTrackingTouch(SeekBarVolumizer sbv) {
|
||||
if (mCallback != null) {
|
||||
mCallback.onStartTrackingTouch(sbv);
|
||||
}
|
||||
}
|
||||
};
|
||||
final Uri sampleUri = mStream == AudioManager.STREAM_MUSIC ? getMediaVolumeUri() : null;
|
||||
if (mVolumizer == null) {
|
||||
@@ -201,5 +207,10 @@ public class VolumeSeekBarPreference extends SeekBarPreference {
|
||||
public interface Callback {
|
||||
void onSampleStarting(SeekBarVolumizer sbv);
|
||||
void onStreamValueChanged(int stream, int progress);
|
||||
|
||||
/**
|
||||
* Callback reporting that the seek bar is start tracking.
|
||||
*/
|
||||
void onStartTrackingTouch(SeekBarVolumizer sbv);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user