mirror of
https://github.com/oxen-io/session-android.git
synced 2025-02-20 06:28:27 +00:00
parent
2f568c6400
commit
9dc003a753
@ -29,6 +29,8 @@ import org.thoughtcrime.securesms.util.Util;
|
|||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
|
import de.greenrobot.event.EventBus;
|
||||||
|
|
||||||
public class AudioView extends FrameLayout implements AudioSlidePlayer.Listener {
|
public class AudioView extends FrameLayout implements AudioSlidePlayer.Listener {
|
||||||
|
|
||||||
private static final String TAG = AudioView.class.getSimpleName();
|
private static final String TAG = AudioView.class.getSimpleName();
|
||||||
@ -76,6 +78,18 @@ public class AudioView extends FrameLayout implements AudioSlidePlayer.Listener
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onAttachedToWindow() {
|
||||||
|
super.onAttachedToWindow();
|
||||||
|
if (!EventBus.getDefault().isRegistered(this)) EventBus.getDefault().registerSticky(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onDetachedFromWindow() {
|
||||||
|
super.onDetachedFromWindow();
|
||||||
|
EventBus.getDefault().unregister(this);
|
||||||
|
}
|
||||||
|
|
||||||
public void setAudio(final @NonNull MasterSecret masterSecret,
|
public void setAudio(final @NonNull MasterSecret masterSecret,
|
||||||
final @NonNull AudioSlide audio,
|
final @NonNull AudioSlide audio,
|
||||||
final boolean showControls)
|
final boolean showControls)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user