remove HistoryInfoItem again

blub
This commit is contained in:
Christian Schabesberger 2018-04-23 16:17:13 +02:00
parent a099fe35d2
commit 5e59cfcf9d
5 changed files with 18 additions and 36 deletions

View File

@ -150,18 +150,6 @@ public abstract class BaseListFragment<I, N> extends BaseStateFragment<I> implem
}
});
infoListAdapter.setOnHistoryItemSelectedListener(new OnClickGesture<HistoryInfoItem>() {
@Override
public void selected(HistoryInfoItem selectedItem) {
onStreamSelected(selectedItem);
}
@Override
public void held(HistoryInfoItem selectedItem) {
showHistoryItemDialog(selectedItem);
}
});
infoListAdapter.setOnChannelSelectedListener(new OnClickGesture<ChannelInfoItem>() {
@Override
public void selected(ChannelInfoItem selectedItem) {

View File

@ -12,7 +12,6 @@ import org.schabi.newpipe.extractor.InfoItem;
import org.schabi.newpipe.extractor.channel.ChannelInfoItem;
import org.schabi.newpipe.extractor.playlist.PlaylistInfoItem;
import org.schabi.newpipe.extractor.stream.StreamInfoItem;
import org.schabi.newpipe.local.history.HistoryInfoItem;
import org.schabi.newpipe.info_list.holder.ChannelInfoItemHolder;
import org.schabi.newpipe.info_list.holder.ChannelMiniInfoItemHolder;
import org.schabi.newpipe.info_list.holder.InfoItemHolder;
@ -51,7 +50,6 @@ public class InfoItemBuilder {
private OnClickGesture<StreamInfoItem> onStreamSelectedListener;
private OnClickGesture<ChannelInfoItem> onChannelSelectedListener;
private OnClickGesture<PlaylistInfoItem> onPlaylistSelectedListener;
private OnClickGesture<HistoryInfoItem> onHistoryItemSelectedListener;
public InfoItemBuilder(Context context) {
this.context = context;
@ -113,11 +111,4 @@ public class InfoItemBuilder {
this.onPlaylistSelectedListener = listener;
}
public OnClickGesture<HistoryInfoItem> getOnHistoryItemSelectedListener() {
return onHistoryItemSelectedListener;
}
public void setOnHistoryItemSelectedListener(OnClickGesture<HistoryInfoItem> onHistoryItemSelectedListener) {
this.onHistoryItemSelectedListener = onHistoryItemSelectedListener;
}
}

View File

@ -10,7 +10,6 @@ import org.schabi.newpipe.extractor.InfoItem;
import org.schabi.newpipe.extractor.channel.ChannelInfoItem;
import org.schabi.newpipe.extractor.playlist.PlaylistInfoItem;
import org.schabi.newpipe.extractor.stream.StreamInfoItem;
import org.schabi.newpipe.local.history.HistoryInfoItem;
import org.schabi.newpipe.info_list.holder.ChannelInfoItemHolder;
import org.schabi.newpipe.info_list.holder.ChannelMiniInfoItemHolder;
import org.schabi.newpipe.info_list.holder.InfoItemHolder;
@ -90,10 +89,6 @@ public class InfoListAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolde
infoItemBuilder.setOnPlaylistSelectedListener(listener);
}
public void setOnHistoryItemSelectedListener(OnClickGesture<HistoryInfoItem> listener) {
infoItemBuilder.setOnHistoryItemSelectedListener(listener);
}
public void useMiniItemVariants(boolean useMiniVariant) {
this.useMiniVariant = useMiniVariant;
}

View File

@ -1,10 +0,0 @@
package org.schabi.newpipe.local.history;
import org.schabi.newpipe.extractor.stream.StreamInfoItem;
import org.schabi.newpipe.extractor.stream.StreamType;
public class HistoryInfoItem extends StreamInfoItem {
public HistoryInfoItem(int serviceId, String url, String name, StreamType streamType) {
super(serviceId, url, name, streamType);
}
}

View File

@ -1,5 +1,23 @@
package org.schabi.newpipe.local.history;
/*
* Copyright (C) Mauricio Colli 2018
* HistoryRecordManager.java is part of NewPipe.
*
* NewPipe is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* NewPipe is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with NewPipe. If not, see <http://www.gnu.org/licenses/>.
*/
import android.content.Context;
import android.content.SharedPreferences;
import android.preference.PreferenceManager;