text stringlengths 14 100k | source stringclasses 1
value | repo stringclasses 810
values | language stringclasses 13
values |
|---|---|---|---|
<|fim_prefix|>package com.liskovsoft<|fim_suffix|> VideoGroup mBaseGroup;
public ChannelUploadsPresenter(Context context) {
super(context);
mBrowseProcessor = new BrowseProcessorManager(getContext(), this::syncItem);
}
public static ChannelUploadsPresenter instance(Context context) {
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.Video;
import com.liskovsoft.smartyoutubetv2.common.app.presenters.base.BasePresenter;
import com.liskovsoft.s... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.googleapi.oauth2.impl.GoogleSignInService;
import com.liskovsoft.sharedutils.mylogger.Log;
import com.liskovsoft.sharedutils.rx.RxHelper;
impo<|fim... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>ents
@Override
public void onSuggestionItemClicked(Video item) {
process(listener -> listener.onSuggestionItemClicked(item));
}
@Override
public void onSuggestionItemLongClicked(Video item) {
process(listener -> listener.onSuggestionItemLongClicked(item));
}
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv<|fim_suffix|>up)
.subscribe(
continueMediaGroup -> {
VideoGroup newGroup = VideoGroup.from(group, continueMediaGroup);
getView().updateSearch(newGroup);
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.smartyoutubetv2.common.app.presenters.base.BasePresenter;
import com.liskovsoft.smartyoutubetv2.common.app.views.SignInView;
public class SignInPre... | fim | yuliskov/SmartTube | java |
package com.liskovsoft.smartyoutubetv2.common.app.presenters;
import android.annotation.SuppressLint;
import android.content.Context;
import android.content.Intent;
import com.liskovsoft.mediaserviceinterfaces.oauth.Account;
import com.liskovsoft.mediaserviceinterfaces.data.MediaGroup;
import com.liskovsoft.shareduti... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>wserView;
public class WebBrowserPresenter extends BasePresenter<WebBrowserView> {
@SuppressLint("StaticFieldLeak")
private static WebBrowserPresenter sInstance;
private String mUrl;
private WebBrowserPresenter(Context context) {
super(context);
}
public static WebBrowse... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>tatic final String QR_SIGN_IN_URL = "https://youtube.com/qr/activate/";
//private static final String SIGN_IN_URL = "https://youtube.com/tv/activate"; // 18+, no search history
//private static final String SIGN_IN_URL = "https://youtube.com/activate"; // age restricted, supports search history
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.base;
import android.app.Activity;
import android.content.Context;
import android.view.View;
import androidx.fragment.app.Fragment;
import com.liskovsoft.mediaserviceinterfaces.CommentsService;
import com.liskovsoft.mediaserviceinterfaces.Con... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs;
import android.content.Context;
import com.liskovsoft.sharedutils.helpers.Helpers;
public class ATVBridgePresenter extends BridgePresenter {
private static final Integer[] ATV_YOUTUBE_PKG_HASH = {-1}; // always reinstall
priva... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>
MediaServiceManager.instance().enableHistory(generalData.isHistoryEnabled());
}
}
private String formatAccount(Account account) {
String format;
if (account.getEmail() != null) {
format = String.format("%s (%s)", account.getName(), account.getEmai... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs;
import android.content.Context;
import com.liskovsoft.sharedutils.helpers.Helpers;
public class AmazonBridgePresenter extends BridgePresenter {
private static final Integer[] AMAZON_YOUTUBE_PKG_HASH = {-1}; // always reinstall
... | fim | yuliskov/SmartTube | java |
package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.appupdatechecker2.AppUpdateChecker;
import com.liskovsoft.appupdatechecker2.AppUpdateCheckerListener;
import com.liskovsoft.sharedutils.helpers.MessageHelp... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.smartyoutubetv2.common.app.presenters.base.BasePresenter;
/**
* Shows boot dialogs one by one.
*/
public class BootDialogPresenter extends... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>mon.app.presenters.AppDialogPresenter;
import com.liskovsoft.smartyoutubetv2.common.app.presenters.base.BasePresenter;
import com.liskovsoft.smartyoutubetv2.common.misc.MotherActivity;
import com.liskovsoft.smartyoutubetv2.common.prefs.GeneralData;
import com.liskovsoft.smartyoutubetv2.common.utils.Loadin... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>} else {
onFinish();
}
}
}
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs;
import android.content.Context;
import com.liskovsoft.sharedutils.helpers.MessageHelpers;
import com.liskovsoft.smartyoutubetv2.common.R;
import com.liskovsoft.smartyoutu... | fim | yuliskov/SmartTube | java |
package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs;
import android.content.Context;
import com.liskovsoft.sharedutils.helpers.DeviceHelpers;
import com.liskovsoft.sharedutils.helpers.DeviceHelpers.ArchType;
public class StableRestorePresenter extends BridgePresenter {
private static final Integ... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs;
import android.content.Context;
import com.liskovsoft.sharedutils.helpers.MessageHelpers;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.Video;
import com.liskovsoft.smartyoutubetv2.common.app.presenters.ChannelUploadsPr... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu;
import android.content.Context;
import com.liskovsoft.mediaserviceinterfaces.MediaItemService;
import com.liskovsoft.mediaserviceinterfaces.data.MediaGroup;
import com.liskovsoft.mediaserviceinterfaces.data.MediaItem;
import com.l... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu;
import android.content.Context;
import com.liskovsoft.mediaserviceinterfaces.MediaItemService;
import com.liskovsoft.mediaserviceinterfaces.ServiceManager;
import com.liskovsoft.mediaserviceinterfaces.data.MediaItem;
import com.li... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu;
import android.content.Context;
import androidx.annotation.Nullable;
import com.liskovsoft.mediaserviceinterfaces.data.MediaGroup;
import com.liskovsoft.mediaserviceinterfaces.data.MediaItem;
import com.liskovsoft.sharedutils.he... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu;
import android.content.Context;
import com.liskovsoft.mediaserviceinterfaces.MediaItemService;
import com.liskovsoft.mediaserviceinterfaces.ServiceManager;
import com.liskovsoft.mediaserviceinterfaces.data.MediaGroup;
import com.l... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>.common.app.presenters.dialogs.menu.providers.channelgroup.RemoveGroupMenuProvider;
import com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu.providers.channelgroup.RenameGroupMenuProvider;
import com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu.providers.channelgroup.Chann... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>ontext context, int idx) {
// NOTE: We can't use the ApplicationContext because providers often use EditDialog internally
mContext = new WeakReference<>(context);
mId = START_ID << idx;
}
public abstract int getTitleResId();
public abstract void onClicked(Video item, V... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>tTitle(), optionItem -> {
BrowsePresenter presenter = BrowsePresenter.instance(getContext());
if (optionItem.isSelected()) {
group.add(mService.createChannel(item.getAuthor(), item.cardImageUrl, item.channelId));
} else {
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu.providers.channelgroup;
import android.annotation.SuppressLint;
import android.content.Context;
import android.net.Uri;
import com.liskovsoft.mediaserviceinterfaces.ChannelGroupService;
import com.liskovsoft.mediaserviceinterfaces... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.<|fim_suffix|>enu.providers.ContextMenuProvider;
import com.liskovsoft.smartyoutubetv2.common.utils.AppDialogUtil;
public class RemoveGroupMenuProvider extends ContextMenuProvider {
private final ChannelGroupServiceWrapper mService;
public Remove... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.dialogs.menu.providers.channelgroup;
import android.content.Context;
import androidx.annotation.NonNull;
import com.liskovsoft.mediaserviceinterfaces.da<|fim_suffix|>YPE_SECTION;
}
}
<|fim_middle|>ta.ItemGroup;
import com.liskovsoft.smart... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.interfaces;
import android.content.Context;
public interface Presenter<T> {
<|fim_suffix|>id onViewResumed();
void onFinish();
}
<|fim_middle|>void setView(T view);
T getView();
void setContext(Context context);
Context get... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>t sectionId);
}
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.interfaces;
public interface SectionPresenter {
void onSectionFocused(int sectionId);
void onSec<|fim_middle|>tionLongPressed(in<|endoftext|> | fim | yuliskov/SmartTube | java |
<|fim_suffix|>n hasPendingActions();
}
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters<|fim_middle|>.interfaces;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.Video;
public interface VideoGroupPresenter {
void onVideoItemSelected(Video item);
void onVideoItemClicked(V... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.service;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.mediaserviceinterfaces.data.MediaGroup;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.smartyoutubetv2.common.R;
i... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>ntext()).start(true));
settingsPresenter.appendSingleButton(updateCheckOption);
}
private void appendUpdateChangelogButton(AppDialogPresenter settingsPresenter) {
List<String> changes = GeneralData.instance(getContext()).getChangelog();
if (changes == null || changes.isE... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.content.Context;
import com.lisk<|fim_suffix|>Checker.setUpdateCheckEnabled(optionItem.isSelected());
}, mUpdateChecker.isUpdateCheckEnabled()));
}
private void appendUpdateCheckButton(AppDialogPresente... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.annotation.SuppressLint;
import android.content.Context;
import android.graphics.drawable.Drawable;
import android.text.TextUtils;
import com.liskovsoft.mediaserviceinterfaces.oauth.Account;
import com.liskovsoft.share... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>ppendCategory(category);
}
private void appendAutoFrameRatePauseCategory(AppDialogPresenter settingsPresenter) {
OptionCategory category = AutoFrameRateController.createAutoFrameRatePauseCategory(getContext(), mPlayerData);
settingsPresenter.appendCategory(category);
}
pr... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.mediaserviceinterfaces.data.MediaGroup;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.sharedutils.helpers.Messag... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.content.Context;
import com.liskovsoft.smartyoutubetv2.common.R;
import com.liskovsoft.smartyoutubetv2.common.app.models.playback.ui.OptionItem;
import com.liskovsoft.smartyoutubetv2.common.app.models.playback.ui.UiOpt... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.annotation.SuppressLint;
import android.content.Context;
import com.liskovsoft.mediaserviceinterfaces.data.MediaGroup;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.sharedutils.helpers.Messag... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app<|fim_suffix|> entry.getValue().equals(country)));
}
settingsPresenter.appendRadioCategory(
getContext().getString(R.string.dialog_select_country) + countryTitle, options);
}
/**
* Gets map of Human readab... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>lobalClockEnabled()));
options.add(UiOptionItem.from(getContext().getString(R.string.player_corner_clock),
option -> mPlayerData.setGlobalClockEnabled(option.isSelected()),
mPlayerData.isGlobalClockEnabled()));
options.add(UiOptionItem.from(getContext().ge... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>ing(R.string.search_background_playback),
option -> mSearchData.setTempBackgroundModeEnabled(option.isSelected()),
mSearchData.isTempBackgroundModeEnabled()));
options.add(UiOptionItem.from(getContext().getString(R.string.player_exit_shortcut) + ": " + getContext()... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>ers.verifyOverlayPermissions(getContext());
// Service that prevents the app from destroying
if (getContext() instanceof MotherActivity) {
((MotherActivity) getContext()).addOnResult(
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.content.Context;
import com.liskovsoft.smartyoutubetv2.common.R;
import com.liskovsoft.smartyoutubetv2.common.app.models.playback.ui.OptionItem;
import com.liskovsoft.smartyoutubetv2.common.app.models.playback.ui.UiOpti... | fim | yuliskov/SmartTube | java |
package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.content.Context;
import android.text.TextUtils;
import androidx.core.content.ContextCompat;
import com.liskovsoft.smartyoutubetv2.common.R;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.Video;
import com.liskovsoft.sma... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>senter) {
OptionCategory category = AppDialogUtil.createSubtitleSizeCategory(getContext());
settingsPresenter.appendRadioCategory(category.title, category.options);
}
private void appendSubtitlePositionCategory(AppDialogPresenter settingsPresenter) {
OptionCategory categor... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.presenters.settings;
import android.content.Context;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.sharedutils.helpers.MessageHelpers;
import com.liskovsoft.smartyoutubetv2.common.R;
import com.liskovsoft.smartyoutubetv2.common.... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.views;
public int<|fim_suffix|>iceView {
void showCode(String userCode);
void close();
}
<|fim_middle|>erface AddDev<|endoftext|> | fim | yuliskov/SmartTube | java |
<|fim_suffix|> boolean isTransparent();
boolean isOverlay();
boolean isPaused();
int getViewId();
}
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.views;
import com.liskovsoft.smartyoutubetv2.common.app.models.playback.ui.OptionCategory;
import java.util.List;
public interface AppDialo... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>outubetv2.common.app.views;
public interface AppUpdateView {
}
<|fim_prefix|>package com.lis<|fim_middle|>kovsoft.smarty<|endoftext|> | fim | yuliskov/SmartTube | java |
<|fim_suffix|>void addSection(int index, BrowseSection section);
void removeSection(BrowseSection category);
void removeAllSections();
void selectSection(int index, boolean focusOnContent);
void updateSection(VideoGroup group);
void updateSection(SettingsGroup group);
void clearSection(BrowseSec... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>update(VideoGroup videoGroup);
void showProgressBar(boolean show);
void clear();
}
<|fim_prefix|>packa<|fim_middle|>ge com.liskovsoft.smartyoutubetv2.common.app.views;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.VideoGroup;
public interface ChannelUploadsView {
void <|endoft... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.views;
import com.liskovsoft.smartyoutu<|fim_suffix|>oid clear();
}
<|fim_middle|>betv2.common.app.models.data.VideoGroup;
public interface ChannelView {
void update(VideoGroup videoGroup);
void setPosition(int index);
void showProgressBar(bo... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.<|fim_suffix|>etailsView {
void openVideo(Video video);
}
<|fim_middle|>smartyoutubetv2.common.app.views;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.Video;
public interface D<|endoftext|> | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.views;
<|fim_suffix|>mon.app.models.playback.manager.PlayerManager;
import com.liskovsoft.smartyoutubetv2.common.app.models.playback.listener.PlayerEventListener;
public interface PlaybackView extends PlayerManager {
void showProgressBar(boolean show... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.views;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.VideoGroup;
import com.liskovsoft.smartyoutubetv2.common.app.models.search.MediaServiceS<|fim_suffix|>on.app.models.search.vineyard.Tag;
public interface SearchView {
void updateSear... | fim | yuliskov/SmartTube | java |
<|fim_suffix|> fullSignInUrl);
void close();
}
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.views;
<|fim_middle|>
public interface SignInView {
void showCode(String userCode, String signInUrl);
void showCode(String userCode, String signInUrl, String<|endoftext|> | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.app.views;
import android.content.Intent;
public interface SplashView {
Intent getNew<|fim_suffix|><|fim_middle|>Intent();
void finishView();
}
<|endoftext|> | fim | yuliskov/SmartTube | java |
package com.liskovsoft.smartyoutubetv2.common.app.views;
import android.annotation.SuppressLint;
import android.app.Activity;
import android.app.Fragment;
import android.content.ActivityNotFoundException;
import android.content.Context;
import android.content.Intent;
import androidx.annotation.NonNull;
import android... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.<|fim_suffix|>etv2.common.app.views;
public interface WebBrowserView {
void loadUrl(String url);
}
<|fim_middle|>liskovsoft.smartyoutub<|endoftext|> | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.autoframerate;
import android.app.Activity;
import android.content.Context;
import android.util.Pair;
import com.liskovsoft.sharedutils.mylogger.Log;
import com.liskovsoft.smartyoutubetv2.common.autoframerate.internal.DisplayHolder.Mode;
import com.liskovsoft... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.autoframerate;
import android.app.Activity;
import android.os.Handler;
import android.os.Looper;
import com.liskovsoft.smartyoutubetv2.common.exoplayer.selector.FormatItem;
public class ModeSyncManager {
private static ModeSyncManager sInstance;
priv... | fim | yuliskov/SmartTube | java |
<|fim_suffix|> {
final int prime = 31;
int result = 1;
result = prime * result + mModeId;
result = prime * result + mHeight;
result = prime * result + mWidth;
result = prime * result + Float.floatToIntBits(mRefreshRate);
return result;
... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>Window window, int videoWidth, float videoFramerate, boolean force) {
if (supportsDisplayModeChange() && videoWidth >= 10) {
if (mUhdHelper == null) {
mUhdHelper = new UhdHelper(mContext);
mUhdHelper.registerModeChangeListener(this);
}
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.autoframerate.internal;
import android.annotation.SuppressLint;
import android.annotation.TargetApi;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.g... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.autoframerate.internal;
import android.view.Window;
/**
* The interface that must be implemented and registered
* with {@link UhdHelper#registerModeChangeListener(UhdHelperListener) registerListener}
* to find out the result of requested mode change.
* <... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer;
import android.annotation.SuppressLint;
import android.content.Context;
import android.net.Uri;
import android.text.TextUtils;
import androidx.annotation.NonNull;
import com.google.android.exoplayer2.C;
import com.google.android.exoplayer2.ext.cron... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer;
import android.net.Uri;
import com.google.android.exoplayer2.C;
import com.google.android.exoplayer2.Format;
import com.google.android.exop<|fim_suffix|>s, mSegmentCount, mMinUpdatePeriodMs);
mInitDone = true;
}
}
}
<|fim_m... | fim | yuliskov/SmartTube | java |
<|fim_suffix|> if (mPlayer == null) {
return -1;
}
return mPlayer.getCurrentPosition();
}
/**
* NOTE: Pos gathered from content block data may slightly exceed video duration
* (e.g. 302200 when duration is 302000).
*/
public void setPositionMs(long positionMs) ... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.controller;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.Video;
public inter<|fim_suffix|>etQualityInfo(String info);
void setVideo(Video video);
}
<|fim_middle|>face PlayerView {
void s<|endoftext|> | fim | yuliskov/SmartTube | java |
<|fim_suffix|>n instanceof FileNotFoundException
|| exception instanceof UnexpectedLoaderException
? C.TIME_UNSET
: Math.min((errorCount - 1) * 1000, 5000);
}
}
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.errors;
import com.google.android.ex... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.errors;
import com.liskovsoft.sharedutils.helpers<|fim_suffix|>faultLoadErrorHandlingPolicy extends DashDefaultLoadErrorHandlingPolicy {
@Override
public long getBlacklistDurationMsFor(int dataType, long loadDurationMs, IOException exception... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>ield(chunk, "nextLoadPosition");
if (nextLoadPosition == 0) {
Log.e(TAG, "Stream position behind the timeline. Waiting for new data...");
try {
Thread.sleep(10_000);
} catch (InterruptedException e) {
e.pri... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.other;
import android.annotation.SuppressLint;
import android.content.Context;
import android.graphics.Color;
import android.net.Uri;
import android.os.Build.VERSION;
import android.text.TextUtils;
import android.util.TypedValue;
import android.view... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.other;
import android.content.Context;
import android.os.Build;
import android.os.Handler;
import androidx.annotation.Nullable;
import com.google.android.exoplayer2.C;
import com.google.android.exoplayer2.DefaultLoadControl;
import com.google.androi... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.other;
import android.content.Context;
import android.graphics.Color;
import android.graphics.Typeface;
import android.os.Build.VERSION;
import android.util.TypedValue;
import android.view.View;
import android.view.accessibility.CaptioningManager;
i... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.lisko<|fim_suffix|>sizeMode(mode);
}
}
<|fim_middle|>vsoft.smartyoutubetv2.common.exoplayer.other;
import com.google.android.exoplayer2.ui.AspectRatioFrameLayout;
import com.google.android.exoplayer2.ui.PlayerView;
/**
* <a href="Zoom to fit video: https://stackoverflow.com/questions/33... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>rgetGain((int) gainMb);
double gainMb = 20 * Math.log10(mVolume * 3) * 100;
mBooster.setTargetGain((int) gainMb);
//mBooster.setTargetGain((int) (1000 * mVolume));
mIsSupported = true;
} catch (RuntimeException | UnsatisfiedLinkError | NoClassDefF... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.selector;
import android.text.TextUtils;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.google.android.exoplayer2.Format;
import com.google.android.exoplayer2.util.MimeTypes;
import com.liskovsoft.sharedutils.he... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>s(String.format("%s,null", "ac-3")); // Note, 5.1 mp4a doesn't work in 5.1 mode
int TYPE_VIDEO = 0;
int TYPE_AUDIO = 1;
int TYPE_SUBTITLE = 2;
int getId();
String getFormatId();
CharSequence getTitle();
boolean isDefault();
boolean isSelected();
boolean isPreset();
... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.selector;
import com.google.android.exoplayer2.Format;
public class TrackInfoFormatter2 {
private String mResolutionStr;
private String mFpsStr;
private String mCodecStr;
private String mBitrateStr;
private String mHdrStr;
p... | fim | yuliskov/SmartTube | java |
<|fim_suffix|> } else if (originLanguage != null && Helpers.startsWith(mediaTrack.format.language, originLanguage)) {
// if (originTracks == null) {
// originTracks = new ArrayList<>();
// }
//
// originTr... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.selector;
import android.text.TextUtils;
import android.util.Pair;
import com.google.android.exoplayer2.Format;
import com.google.android.exoplayer2.Player;
import com.google.android.exoplayer2.util.MimeTypes;
import com.liskovsoft.sharedutils.helpe... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.selector.track;
import com.google.android.exoplayer2.Format;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.smartyoutubetv2.common.exoplayer.selector.TrackSelectorUtil;
public class AudioTrack extends MediaTrack {
publ... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.selector.track;
import com.google.android.exoplayer2.Format;
import com.google.android.exoplayer2.source.TrackGroupArray;
import com.google.android.exoplayer2.trackselection.TrackSelection.Definition;
import com.liskovsoft.sharedutils.helpers.Helper... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.selector.track;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.youtubeapi.videoinfo.models.TranslatedCaptionTrack;
import java.util.regex.Pattern;
public class SubtitleTrack extends MediaTrack {
private static final P... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.selector.track;
import com.google.android.exoplayer2.Format;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.smartyoutubetv2.common.exoplayer.selector.TrackSelectorUtil;
public class VideoTrack extends MediaTrack {
priv... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.versions;
import com.google.android.exoplayer2.ExoPlayer;
import com.google.android.exoplayer2.mediacodec.MediaCodecInfo;
import com.google.android.exoplayer2.mediacodec.MediaCodecUtil;
import com.google.android.exoplayer2.mediacodec.MediaCodecUtil.... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.versions.renderer;
import android.content.Con<|fim_suffix|> //public CustomOverridesRenderersFactory(Context activity) {
// super(activity);
//
// mPlayerData = PlayerData.instance(activity);
// mPlayerTweaksData = PlayerTw... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>AudioRenderer = renderer;
break;
}
index++;
}
if (originMediaCodecAudioRenderer != null) {
// replace origin with custom
renderers.remove(originMediaCodecAudioRenderer);
renderers.a... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.versions.renderer;
import android.content.Context;
import android.media.MediaCodec;
import android.os.Build.VERSION;
import android.os.Handler;
import android.view.Surface;
import androidx.annotation.Nullable;
import com.google.android.exoplayer2.C;... | fim | yuliskov/SmartTube | java |
package com.liskovsoft.smartyoutubetv2.common.exoplayer.versions.renderer;
import android.content.Context;
import android.media.MediaCodec;
import android.os.Handler;
import androidx.annotation.Nullable;
import com.google.android.exoplayer2.ExoPlaybackException;
import com.google.android.exoplayer2.Format;
import com.... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.versions.renderer;
import android.annotation.TargetApi;
import android.content.Context;
import android.media.MediaCodec;
import android.os.Handler;
import androidx.annotation.Nullable;
import com.google.android.exoplayer2.Format;
import com.google.a... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.versions.selector;
import androidx.annotation.Nullable;
import com.google.android.exoplayer2.mediacodec.MediaCodecInfo;
import com.google.android.exoplayer2.mediacodec.MediaCodecSelector;
import com.google.android.exoplayer2.mediacodec.MediaCodecUti... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>oups, params, definitionPair.first);
}
return definitionPair;
}
private void unlockAllVideoFormats(int[][] formatSupports) {
final int videoTrackIndex = 0;
for (int j = 0; j < formatSupports[videoTrackIndex].length; j++) {
if (formatSupports[videoTrac... | fim | yuliskov/SmartTube | java |
<|fim_suffix|>.Factory().createTrackSelection(group, null, tracks);
//}
}
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.exoplayer.versions.selector.backport;
import androidx.annotation.Nullable;
import com.google.android.exoplayer2.C;
import com.google.android.exoplayer2.source.TrackGroup;
import com... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.misc;
import android.content.Context;
import com.liskovsoft.sharedutils.helpers.Helpers;
import com.liskovsoft.smartyoutubetv2.common.R;
import com.liskovsoft.smartyoutubetv2.common.app.models.data.SettingsItem;
import com.liskovsoft.smartyoutubetv2.common.ap... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.misc;
import android.app.Notification;
import android.app.NotificationChannel;
import android.app.NotificationManager;
import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.os.Build;
import android.os.IBinde... | fim | yuliskov/SmartTube | java |
<|fim_prefix|>package com.liskovsoft.smartyoutubetv2.common.misc;
import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.content.pm.PackageManager;
import android.database.Cursor;
import android.net.Uri;
import android.os.Build.VERSION;
import android.provider.Openab... | fim | yuliskov/SmartTube | java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.