mirror of
https://github.com/NiciDieNase/chaosflix
synced 2024-11-27 06:30:29 +00:00
distinguish between recording in stream for progress
This commit is contained in:
parent
7784c98688
commit
7ae89cabeb
1 changed files with 15 additions and 7 deletions
|
@ -167,10 +167,14 @@ public class OverlayFragment extends PlaybackFragment{
|
|||
ps.addClassPresenter(ListRow.class, new ListRowPresenter());
|
||||
mRowsAdapter = new ArrayObjectAdapter(ps);
|
||||
mRowsAdapter.add(controlsRow);
|
||||
if(eventType == DetailsActivity.TYPE_RECORDING){
|
||||
if(mSelectedEvent.getMetadata() != null && mSelectedEvent.getMetadata().getRelated() != null){
|
||||
mRowsAdapter.add(getRelatedItems());
|
||||
setOnItemViewClickedListener(new ItemViewClickedListener(this));
|
||||
}
|
||||
} else if(eventType == DetailsActivity.TYPE_STREAM){
|
||||
// TODO add other streams as related events
|
||||
}
|
||||
setAdapter(mRowsAdapter);
|
||||
|
||||
if(mCallback != null && eventType == DetailsActivity.TYPE_STREAM){
|
||||
|
@ -237,16 +241,20 @@ public class OverlayFragment extends PlaybackFragment{
|
|||
}
|
||||
|
||||
public int getCurrentPosition() {
|
||||
if(eventType == DetailsActivity.TYPE_RECORDING){
|
||||
if(mCallback != null){
|
||||
return (int) mCallback.getCurrentPosition();
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
private long getCurrentPositionLong(){
|
||||
if(eventType == DetailsActivity.TYPE_RECORDING){
|
||||
if(mCallback != null){
|
||||
return mCallback.getCurrentPosition();
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue