mirror of
https://github.com/TeamNewPipe/NewPipe.git
synced 2024-11-24 20:15:16 +01:00
Some more slight improvements
This commit is contained in:
parent
32d2606a65
commit
b85f7a6747
@ -26,11 +26,11 @@ public class DescriptionFragment extends BaseDescriptionFragment {
|
||||
@State
|
||||
StreamInfo streamInfo;
|
||||
|
||||
|
||||
public DescriptionFragment(final StreamInfo streamInfo) {
|
||||
this.streamInfo = streamInfo;
|
||||
}
|
||||
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
protected Description getDescription() {
|
||||
|
@ -26,10 +26,8 @@ public class ChannelAboutFragment extends BaseDescriptionFragment {
|
||||
@State
|
||||
protected ChannelInfo channelInfo;
|
||||
|
||||
public static ChannelAboutFragment getInstance(final @NonNull ChannelInfo channelInfo) {
|
||||
final ChannelAboutFragment fragment = new ChannelAboutFragment();
|
||||
fragment.channelInfo = channelInfo;
|
||||
return fragment;
|
||||
ChannelAboutFragment(@NonNull final ChannelInfo channelInfo) {
|
||||
this.channelInfo = channelInfo;
|
||||
}
|
||||
|
||||
|
||||
@ -42,10 +40,7 @@ public class ChannelAboutFragment extends BaseDescriptionFragment {
|
||||
@Nullable
|
||||
@Override
|
||||
protected Description getDescription() {
|
||||
return new Description(
|
||||
channelInfo.getDescription(),
|
||||
Description.PLAIN_TEXT
|
||||
);
|
||||
return new Description(channelInfo.getDescription(), Description.PLAIN_TEXT);
|
||||
}
|
||||
|
||||
@NonNull
|
||||
|
@ -474,7 +474,7 @@ public class ChannelFragment extends BaseStateFragment<ChannelInfo>
|
||||
if (ChannelTabHelper.showChannelTab(
|
||||
context, preferences, R.string.show_channel_tabs_about)) {
|
||||
tabAdapter.addFragment(
|
||||
ChannelAboutFragment.getInstance(currentInfo),
|
||||
new ChannelAboutFragment(currentInfo),
|
||||
context.getString(R.string.channel_tab_about));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user